import React, { ReactNode, forwardRef } from 'react' import { twMerge } from 'tailwind-merge' import './styles.scss' import { Cross2Icon } from '@radix-ui/react-icons' export interface Props extends React.InputHTMLAttributes { textAlign?: 'left' | 'right' prefixIcon?: ReactNode suffixIcon?: ReactNode onCLick?: () => void clearable?: boolean onClear?: () => void } const Input = forwardRef( ( { className, type, textAlign, prefixIcon, suffixIcon, onClick, onClear, clearable, ...props }, ref ) => { return (
{prefixIcon && (
{prefixIcon}
)} {suffixIcon && (
{suffixIcon}
)} {clearable && (
)}
) } ) export { Input }