Skip to content

Tabs ​

catnip-tabs is a horizontal tab rail: every item is a button (or a menu trigger with button rows). Bind modelValue for the active tab or submenu row value, and use @update:modelValue to drive in-page panels or client-side routing (no full document reload). Set tabsAriaLabel to name the nav when context is not obvious.

Live example ​

The Configuration panel edits a single live catnip-tabs: the default items JSON is a hybrid example (Overview / Secrets / Permissions with a menu). Change modelValue to match a top-level value or a submenu row value for correct active styling.

Changing the URL without a full reload ​

Handle @update:modelValue and call your router (for example VitePress useRouter().go(withBase(path)), or Vue Router push) so the address bar updates while staying in SPA mode.

Guidelines ​

  • Use @update:modelValue and your router when tabs should match shareable URLs (no full page reload in an SPA).
  • Use menu when one rail label opens a short list of related options (optional icon / count per row). Keep .modelValue in sync with the active row value when using menu selection.
  • Use count for short numeric badges (unread, totals). For long text or non‑numeric values, keep the label descriptive and omit count.

Catnip Design System by Signicat