Tabs
Reusable React exports, live props, and complete source.
'use client';
import { useState } from 'react';
import { Tabs } from '@helios-ui/react';
import '@helios-ui/react/styles.css';
export default function Example() {
const [value, setValue] = useState("overview");
return (
<Tabs label="Example sections" value={value} onValueChange={setValue} items={[{id:"overview",label:"Overview",content:"Overview content"},{id:"activity",label:"Activity",content:"Activity content"},{id:"settings",label:"Settings",content:"Settings content",disabled:false}]} />
);
}
Customize this example
Use in your React app
Download the local package, install its React peers, then import the export and stylesheet. This package is not published to npm.
npm install react@^19 react-dom@^19 ./helios-ui-react-0.1.0.tgzDownload React package ↓Download all source (JSON) ↓The Code tab renders the same exports used in this preview. Source files include typed props, behavior, styles, and dependency details.
Icons & counts
Underline tabs connect each control with its own panel. Arrows, Home and End move selection and focus.
'use client';
import {useState} from 'react';
import {Tabs} from '@helios-ui/react';
import '@helios-ui/react/styles.css';
export default function Example(){
return (<Tabs label="Workspace content" items={[{"id":"banners","label":"Banners","icon":"▣","count":152,"content":"152 example banners are available in this local workspace."},{"id":"posts","label":"Posts","icon":"▤","count":32,"content":"32 example posts are ready to review."},{"id":"codes","label":"QR codes","icon":"▦","count":14,"content":"14 example QR codes are available."},{"id":"members","label":"Members","content":"Manage the members of this sample workspace."},{"id":"settings","label":"Settings","content":"Adjust this local example’s settings."}]}/>);
}
Pill tabs
Rounded blue-accent and gray treatments support local view switching with the same keyboard behavior.
'use client';
import {useState} from 'react';
import {Tabs} from '@helios-ui/react';
import '@helios-ui/react/styles.css';
export default function Example(){
return (<><Tabs label="Agent view" variant="pill" items={[{id:'changes',label:'Changes',content:'Review the local change list.'},{id:'browser',label:'Browser',content:'Preview this sample browser view.'}]}/><Tabs label="Source scope" variant="gray" items={[{id:'home',label:'Home',content:'Home source selected.'},{id:'local',label:'Local',content:'Local source selected.'},{id:'cloud',label:'Cloud',content:'Cloud example selected; no external service is connected.'}]}/></>);
}
Props
Generated from the TypeScript export Tabs. Configure this example with the preview controls above.
| Prop | Type / behavior |
|---|---|
label | string |
items | Tab[] |
value | string | undefined |
defaultValue | string | undefined |
onValueChange | ((value: string) => void) | undefined |
variant | "underline" | "pill" | "gray" | undefined |
Explore composed examples
Built from the same components
Forms, tables, charts and composers share Button, Input, Select, Checkbox, Tabs and Dialog.
Team members
Fictional records · client-side sorting, selection and export
| Action | |||||
|---|---|---|---|---|---|
Aarav Shahaarav@example.com | Designer | ₹1,250 | |||
Diya Raodiya@example.com | Developer | ₹2,500 | |||
Ishaan Patelishaan@example.com | Admin | ₹3,750 | |||
Kavya Nairkavya@example.com | Designer | ₹5,000 | |||
Rohan Mehtarohan@example.com | Developer | ₹6,250 |
Revenue overview
Illustrative INR data · totals match the visible period
Jan: ₹4,200
Accessible data table
| Month | Revenue |
|---|---|
| Jan | ₹4,200 |
| Feb | ₹5,100 |
| Mar | ₹4,600 |
| Apr | ₹6,800 |
| May | ₹5,900 |
| Jun | ₹7,200 |
Team conversation
Local composer example · Enter sends, Shift+Enter adds a line
No messages yet. Start a conversation below.
Keyboard and motion
Tab reaches controls; Space and Enter activate buttons. Native Select supports keyboard selection and mobile pickers. Tabs use arrows, Home and End. Dialog contains focus, closes with Escape, and restores focus. Data tables expose sort and selection state. Reduced motion removes spinners and chart transitions.
Primary labels adapt to the chosen accent for contrast. This accessibility adjustment differs from Figma’s white-on-cyan example. The Select example uses a React Aria popover with rich option content and keyboard typeahead. Native Select remains available for simple platform-picker integrations.