Navigation rail group
ProA rail destination that opens a secondary column of links on hover or focus, and folds as an accordion in an expanded rail. Not an M3 component (@windmorph/react-pro).
import { NavigationRailGroup, NavigationRailGroupItem } from '@windmorph/react-pro';Part of Windmorph Pro, paid components on the free core, not on sale yet. See the Pro guide for what it includes and to register interest.
Keyboard
| Key | Action | Where |
|---|---|---|
| Tab | Moves through the destinations, and into an open column’s links. | |
| Arrow Up or Arrow Down | Move between the rail’s destinations.In the rail | In the rail |
| Enter | Follows the focused link. | |
| Escape | Closes a preview and returns focus to its destination. |
Keyboard focus opens a column at once; a column someone is reading by keyboard stays open when the pointer leaves.
Screen reader
- Role
- Destinations are links in the rail’s
nav; the column is agroup. In an expanded rail, a group is an accordion. - Accessible name
- The destination’s
label; the column takesaria-label, or the label. - States announced
- A destination has
aria-expandedandaria-controls. The current link hasaria-current="page", and a closed column isinert.
A group that holds the current page shows as current without claiming to be the page.
Focus
- Closing a preview with focus inside it hands focus to its destination first.
- Each link shows the M3 focus indicator from the keyboard.
Touch target
- Destinations are the rail’s, and links are 48px rows at density 0.
- Touch only navigates: there’s no preview to dismiss.
Motion
- The column’s width springs open and closes without a bounce. Under reduced motion it only fades.
- In forced colours the column keeps a
CanvasTextedge and the current link keepsHighlight.
What you need to do
- Pass
currentPath, orcurrenton an item, so the right link is marked. - With
pinned, leave room for the column in your layout. - Wrap your app in React Aria’s
RouterProviderfor client-side navigation.