NavigationRailItem

A single destination inside a `NavigationRail`; renders as a link when `href` is provided, otherwise as a button.

Props

React props
NameTypeRequiredDefaultDescription
classNamestring | ClassNameComponent<NavigationRailItemInterface>NoClasses or state-aware element classes applied through the shared style contract.
selectedbooleanNofalseControlled selected state, used when no parent drives the selection.
variant"vertical" | "horizontal"No'vertical'Injected by the parent NavigationRail: layout direction of the item.
indexnumberNoInjected by the parent NavigationRail: position of this item in the rail.
selectedItemnumberNoInjected by the parent NavigationRail: index of the currently selected item.
isExtendedbooleanNoInjected by the parent NavigationRail: whether the rail is extended.
extendedOnlybooleanNoInjected by the parent NavigationRail: hide the item while the rail is collapsed.