An Indigo-branded tabs component with smooth indicator transitions and full ARIA keyboard navigation support.
Interactive element that switches between different content views.
A bottom Indigo-600 line that animates between active tabs.
// ExperimentTabs.tsx
const ExperimentTabs = ({ tabs, activeId, onChange }) => (
<div className="flex border-b">
{tabs.map(tab => (
<button
className={`px-6 py-3 relative ${activeId === tab.id ? 'text-indigo-600' : ''}`}
onClick={() => onChange(tab.id)}
>
{tab.label}
{activeId === tab.id && <div className="absolute bottom-0 left-0 right-0 h-0.5 bg-indigo-600" />}
</button>
))}
</div>
);