Holiday Notice: Support will be provided on a limited scale from December 24th, 2024, to January 2nd, 2025. Happy holidays and a wonderful New Year!


Topic: Content goes above fixed SideNav & fixed Navbar

ribomation pro asked 6 years ago


I'm struggling with realizing the "fixed SideNav & fixed Navbar" layout. The content (main) is scrolling above the topnav, instead of under it.

Please, help me trouble-shoot and what should I look for.

Here is the overall app layout

<header>
<mdb-side-nav #sidenav class="sidebar-bg fixed" [fixed]="true" [sidenavBreakpoint]="900">
<li>...logo...</li>
<li>...menu...</li>
<div class="sidenav-bg mask-light"></div>
</mdb-side-nav>

<mdb-navbar SideClass="navbar fixed-top navbar-toggleable-md navbar-expand-lg scrolling-navbar double-nav" [containerInside]="false">
<navlinks class="navbar-container">
<div class="float-left"><!-- SideNav slide-out button -->
<a (click)="sidenav.show()" class="button-collapse"><i class="fa fa-bars"></i></a>
</div>
</navlinks>
<mdb-navbar-brand>...</mdb-navbar-brand>
<navlinks>...</navlinks>
</mdb-navbar>
</header>
<main >
<div class="container-fluid mt-5" >
<router-outlet></router-outlet>
</div>
</main>

//Here is the body part
<body class="fixed-sn">
<app-root></app-root>
<noscript>Please enable JavaScript to continue using this application.</noscript>
</body>
</html>

//Where app-root consists of just
<router-outlet></router-outlet>

 


ribomation pro answered 6 years ago


That, did the trick. Thanks a lot.

Please, add some remarks to the docs as well, for the next guy.


Arkadiusz Idzikowski staff answered 6 years ago


Hello,

I think that in this case the problem is caused by a transparent background of the navbar. Please try to add 'white' class to the SideClass input.



Please insert min. 20 characters.

FREE CONSULTATION

Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.

Status

Resolved

Specification of the issue

  • ForumUser: Pro
  • Premium support: No
  • Technology: MDB Angular
  • MDB Version: 7.0.0
  • Device: Laptop
  • Browser: Chrome
  • OS: Windows 10
  • Provided sample code: Yes
  • Provided link: No