Component packs › Keycap › Key Row Tabs
The active key stays half down with its LED lit; press another and it latches while the old key springs back up.
Key Row Tabs is a tabs from Keycap, a component pack with 6 keyboard controls: Controls made of mechanical keyboard keys: real travel, a tactile bump and a switch LED under every cap. Price: $2 for the whole pack.
Built with: radio latch, roving focus, LED per key.
Code: React and Next.js (TypeScript), Vue 3, plain HTML/CSS/JS, Tailwind CSS v4 and Motion (motion.dev). No npm packages needed. Keyboard accessible, with a reduced-motion version, in dark and light.
| Prop | Type | Default | Description |
|---|---|---|---|
tabs | string[] | Overview, Activity, Billing, Team | Tab names. Default Overview, Activity, Billing, Team. |
panels | string[] | Panel text for each tab (optional). | |
value | number | 0 | Selected index. Default 0. |
label | string | "Sections" | Accessible name of the tab list. Default "Sections". |
onChange | (index: number) => void |
readonly value: numberselect(index: number, silent?: boolean): voiddestroy(): voidimport KeyRowTabs from './KeyRowTabs';
<KeyRowTabs />The Vue, HTML, Next.js, Tailwind and Motion versions take the same options.
Good for: Buttons.