'use client' interface Option { key: string label: string subtitle: string } interface Props { options: Option[] active: string onChange: (key: string) => void } export default function SegmentedToggle({ options, active, onChange }: Props) { return (
{options.map(o => ( ))}

{options.find(o => o.key === active)?.subtitle}

) }