"use client"; import * as React from "react"; import { cn } from "@/lib/utils"; /** * Section header shared by every settings page. On phones the layout renders the back bar with the * section title, so we only show the description there; on desktop the title + description stand at * the top of the content column. */ export function SettingsSection({ title, description, actions, children, className }: { title: string; description?: React.ReactNode; actions?: React.ReactNode; children: React.ReactNode; className?: string }) { return (

{title}

{description ?

{description}

: null}
{actions ?
{actions}
: null}
{children}
); } /** Grouped rows with hairlines (iOS-style list) — used for toggles and key/value rows on every breakpoint. */ export function SettingsGroup({ title, description, children, className, footer }: { title?: React.ReactNode; description?: React.ReactNode; children: React.ReactNode; className?: string; footer?: React.ReactNode }) { return (
{title ? (

{title}

{description ?

{description}

: null}
) : null}
{children}
{footer ?

{footer}

: null}
); } /** One row: label + optional description on the left, control on the right. min-h 44 px. */ export function SettingsRow({ label, description, children, htmlFor, className }: { label: React.ReactNode; description?: React.ReactNode; children?: React.ReactNode; htmlFor?: string; className?: string }) { return (
{htmlFor ? ( ) : (

{label}

)} {description ?

{description}

: null}
{children ?
{children}
: null}
); }