import type { TextFieldProps } from "../config/interfaces.config"; import { FormControl, FormLabel, Input } from "@mui/joy"; export const TextField = ({ label, type = "text", required, errors, value, onBlur, onChange, slotProps, afterInput, }: TextFieldProps) => ( {label} onChange(e.target.value)} type={type} variant="soft" sx={{ borderRadius: "10px" }} slotProps={slotProps} /> {afterInput} {errors[0] ? ( {errors[0]} ) : null} );