import type { ReactNode } from 'react'; /** * A section header with title and optional description, separated by a border. */ export function SettingSection({ title, description, children, }: { title?: string; description?: string; children: ReactNode; }) { return (
{title &&

{title}

} {description &&

{description}

}
{children}
); } /** * A single settings row: label+description on the left, action on the right. * Use for toggles, inputs, buttons, badges — any control type. */ export function SettingRow({ title, description, htmlFor, action, children, }: { title: string; description?: string; htmlFor?: string; /** Right-aligned control (checkbox, button, badge, etc.) */ action?: ReactNode; /** Full-width content rendered below the label row (for sliders, inputs, etc.) */ children?: ReactNode; }) { return (
{description &&

{description}

}
{action &&
{action}
}
{children &&
{children}
}
); }