How to change container to container fluid in Angular Bootst


Topic: How to change container to container fluid in Angular Bootstrap mega menu component

tattoodxb asked 6 years ago

By default angular mega menu component outputs


<nav class="navbar navbar-expand-lg p-0 ">
<div class="container" ng-reflect-ng-class="[object Object]" ng-reflect-ng-style="[object Object]">
<a _ngcontent-c1="" class="navbar-brand logo-link" href="#">Navbar</a>
</div>
</nav>

However i want to change the (container) class to (container-fluid) as design requirements, so it will be like

<nav class="navbar navbar-expand-lg p-0 ">
<div class="container-fluid" ng-reflect-ng-class="[object Object]" ng-reflect-ng-style="[object Object]">
<a _ngcontent-c1="" class="navbar-brand logo-link" href="#">Navbar</a>
</div>
</nav>

Thanks in advance


Arkadiusz Idzikowski staff answered 6 years ago

Hello,

Unfortunately there is no easy way to add custom class to this element. You can remove the container from mdb-navbar component with [containerInside]="false".

<mdb-navbar [containerInside]="false"></mdb-navbar>

Regards,

Arek


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
  • User: Free
  • Premium support: No
  • Technology: MDB Angular
  • MDB Version: 6.2.3
  • Device: mac
  • Browser: chrome
  • OS: mojave
  • Provided sample code: Yes
  • Provided link: No