import React from "react"; interface Tab { id: T; label: string; } interface Props { tabs: Tab[]; active: T; onChange: (id: T) => void; /** Optional content rendered on the right side of the toolbar */ actions?: React.ReactNode; } export function ToolbarTabs({ tabs, active, onChange, actions, }: Props) { return (
{tabs.map((tab) => ( ))}
{actions && (
{actions}
)}
); }