import React from 'react'; import { FieldError, Input, Label, Text, TextField as RACTextField, type TextFieldProps as RACTextFieldProps, type ValidationResult, } from 'react-aria-components'; export interface TextFieldProps extends RACTextFieldProps { label?: string; description?: string; errorMessage?: string | ((validation: ValidationResult) => string); placeholder?: string; } export function TextField({ label, description, errorMessage, ...props }: TextFieldProps) { return ( {description && {description}} {errorMessage} ); }