Dock

Fixed bottom navigation bar for mobile app shells with up to 5 items

Category: navigation · WCAG 2.2-AA · dock, tab-bar, bottom-nav, mobile, navigation, app-shell

States

Props

PropTypeDefaultDescription
ariaLabelstringAccessible label for the dock navigation; defaults to the built-in i18n string.
itemsDockItem[]Navigation items, each with a label, icon, and optional href or onClick
activeIndexnumberIndex of the currently active item (0-based)
classNamestringAdditional CSS class names merged onto the root element.

Design tokens

When to use

When not to use

How to build an accessible Dock in React →

Examples

Basic mobile dock

Fixed bottom navigation for a mobile app shell

<Dock
  activeIndex={0}
  items={[
    { label: 'Home', icon: '🏠', onClick: () => navigate('/') },
    { label: 'Search', icon: '🔍', onClick: () => navigate('/search') },
    { label: 'Profile', icon: '👤', onClick: () => navigate('/profile') },
  ]}
/>

With hrefs

Link-based dock items for standard navigation

<Dock
  activeIndex={1}
  items={[
    { label: 'Feed', icon: '📰', href: '/feed' },
    { label: 'Explore', icon: '🌐', href: '/explore' },
    { label: 'Notifications', icon: '🔔', href: '/notifications' },
    { label: 'Profile', icon: '👤', href: '/profile' },
  ]}
/>

Related components

← Back to docs