import * as React from "react" import { CopyIcon, PencilIcon, type LucideIcon } from "lucide-react" import { cn } from "@/lib/utils" import { copyToClipboard } from "@/lib/clipboard" /** Смысловой блок на мягкой подложке: иконка + заголовок, справа — действие; с `onEdit` — карандаш при наведении. */ export function InfoSection({ icon: Icon, title, action, onEdit, className, children, }: { icon?: LucideIcon title: React.ReactNode action?: React.ReactNode /** Редактирование блока — обычно открывает EditDialog. */ onEdit?: () => void className?: string children: React.ReactNode }) { return (

{Icon && } {title} {(action || onEdit) && ( {action} {onEdit && ( )} )}

{children}
) } /** Подпись + значение; с `copy` — кнопка копирования при наведении. */ export function Field({ label, copy, className, children, }: { label: string copy?: string className?: string children: React.ReactNode }) { return (
{label} {copy && ( )}
{children}
) }