UnderlineNav

Use the UnderlineNav component to style navigation with a minimal underlined selected state, typically used for navigation placed at the top of the page.
@primer/react@v37.14.0DeprecatedNot reviewed for accessibility

Deprecation

Use the new version of UnderlineNav with design and accessibility updates.

Attention: Make sure to properly label your UnderlineNav with an aria-label to provide context about the type of navigation contained in UnderlineNav.

Examples

UnderlineNav

NameTypeDefaultDescription
ActionsReact.ReactNodePlace another element, such as a button, to the opposite side of the navigation items.
align'right'Use right to have navigation items aligned right.
fullbooleanUsed to make navigation fill the width of the container.
aria-labelstringUsed to set the aria-label on the top level <nav> element.
sxSystemStyleObject
NameTypeDefaultDescription
asReact.ElementType'a'The underlying element to render — either a HTML element name or a React component.
hrefstring
selectedboolean
sxSystemStyleObject