Nav

Nav is a hierarchical, vertical navigation and can include nested menu items.


Sage Component

SageNav
<%= sage_component SageNav, {
  aria_label: "Example Navigation",
  items: [
    { link: "#", text: "Nav Link 1", active: true },
    { link: "#", text: "Nav Link 2" },
    { link: "#", text: "Nav Link 3", items: [
      { link: "#", text: "Nav Sub Link 1", type: "sub" },
      { link: "#", text: "Nav Sub Link 2", type: "sub" },
      { link: "#", text: "Nav Sub Link 3", type: "sub" }
    ]},
    { link: "#", text: "Nav Link 4" },
    { link: "#", text: "Nav Link 5" }
  ]
} %>
Property Description Type Default

aria_label

Sets the aria-label for the nav component.

String

nil

items

Provides a list of items to automate displaying inside this Nav.

Array of items with the same structure as NavLinks

nil