Skip to main content

Navbar

Documentation and examples for boodoo's powerful, responsive navigation header, the navbar. Includes support for branding, navigation, collapse plugin, and more.

How it works

  • Navbars require a wrapping .navbar with .navbar-expand{-sm|-md|-lg|-xl|-xxl} for responsive collapsing, and a color scheme class.
  • Content inside .navbar-collapse collapses below the given breakpoint.
  • Navbars and their contents are fluid by default. Optional .container can wrap an expanded navbar's contents.

Basic navbar

<nav class="navbar navbar-expand-lg navbar-light bg-white">
  <div class="container-fluid">
    <a class="navbar-brand" href="#">Navbar</a>
    <button class="navbar-toggler" type="button"
            data-boodoo-toggle="collapse" data-boodoo-target="#nav">
      <span class="navbar-toggler-icon"></span>
    </button>
    <div class="collapse navbar-collapse" id="nav">
      <ul class="navbar-nav me-auto">
        <li class="nav-item"><a class="nav-link active" href="#">Home</a></li>
        <li class="nav-item"><a class="nav-link" href="#">Link</a></li>
      </ul>
    </div>
  </div>
</nav>

Color schemes

Themed navbars come in a handful of baked-in options: .navbar-light, .navbar-dark, and per-color .navbar-{primary|success|...}.

Fixed & sticky

Add classes like .navbar-sticky-top, .navbar-fixed-top, or .navbar-fixed-bottom to pin the navbar.

<nav class="navbar navbar-expand-lg navbar-sticky-top">...</nav>

Blur & transparent

Combine .navbar-transparent (no background) with .navbar-blur for a frosted-glass effect:

<nav class="navbar navbar-expand-lg navbar-transparent navbar-blur">...</nav>