/** * Компонент поля формы с валидацией */ 'use client'; import { ReactNode } from 'react'; interface FormFieldProps { label: string; name: string; error?: string; required?: boolean; children: ReactNode; hint?: string; } export default function FormField({ label, name, error, required = false, children, hint, }: FormFieldProps) { const labelId = `${name}-label`; const errorId = error ? `${name}-error` : undefined; const hintId = hint ? `${name}-hint` : undefined; const describedBy = [hintId, errorId].filter(Boolean).join(' ') || undefined; return (