Angular Navs Base navs

The base c-nav component is built with flexbox and provide a strong foundation for building all types of navigation components. It includes some style overrides (for working with lists), some link padding for larger hit areas, and basic [disabled]="true" styling.

Active Link Link Disabled

Classes are used throughout, so your markup can be super flexible. Use c-nav-item like above, or roll your own with a <c-nav> element. Because the .nav uses display: flex, the cNavLink behaves the same as c-nav-item would, but without the extra markup.

Active Link Link Disabled
Angular Navs Horizontal alignment

Change the horizontal alignment of your nav with flexbox utilities . By default, navs are left-aligned, but you can easily change them to center or right aligned.

Centered with .justify-content-center:

Active Link Link Disabled

Right-aligned with .justify-content-end:

Active Link Link Disabled
Angular Navs Vertical

Stack your navigation by changing the flex item direction with the .flex-column utility. Need to stack them on some viewports but not others? Use the responsive versions (e.g., .flex-sm-column).

Active Link Link Disabled
Angular Navs Tabs

Take the basic nav from above and add the variant="tabs" class to generate a tabbed interface

Active Link Link Disabled
Angular Navs Pills

Take that same HTML, but use variant="pills" instead:

Active Link Link Disabled
Angular Navs Underline

Take that same HTML, but use variant="Underline" instead:

Active Link Link Disabled
Angular Navs Fill and justify

Force your .nav's contents to extend the full available width one of two modifier classes. To proportionately fill all available space with your .nav-items, use layout="fill". Notice that all horizontal space is occupied, but not every nav item has the same width.

Active Link Link Disabled

For equal-width elements, use layout="justified". All horizontal space will be occupied by nav links, but unlike the .nav-fill above, every nav item will be the same width.

Active Link Link Disabled
Angular Navs Working with flex utilities

If you need responsive nav variations, consider using a series of flexbox utilities. While more verbose, these utilities offer greater customization across responsive breakpoints. In the example below, our nav will be stacked on the lowest breakpoint, then adapt to a horizontal layout that fills the available width starting from the small breakpoint.

Active Link Link Disabled
Angular Navs Tabs with dropdowns
Angular Navs Pills with dropdowns Active Dropdown button Link Disabled