import React, { Children, useMemo } from 'react' import { IFormField } from './FormField.interface' import { StyledFieldContainer } from './FormField.theme' import { getId } from '@/helpers/uuid' export const FormField = ({ id, label, leftIcon, rightIcon, isCheckRadio, className, children, ...props }: IFormField) => { const itemID = id ? id : useMemo(() => getId(), []) return ( {label && ( )}
{leftIcon && leftIcon} {children} {rightIcon && rightIcon}
) } export default FormField