fix: remove receiving non-boolean attribute console warning

This commit is contained in:
lonyele 2019-06-25 15:41:27 +09:00
parent f420cbbaaa
commit 220b17e8aa

View File

@ -11,9 +11,13 @@ import { OnEmitEvent } from '../index';
interface StyledTextareaProps {
shown: boolean;
failed: boolean;
value?: string;
onChange?: (event: React.ChangeEvent<HTMLTextAreaElement>) => void;
}
const StyledTextarea = styled(Textarea)<StyledTextareaProps>(
const StyledTextarea = styled(({ shown, failed, ...rest }: StyledTextareaProps) => (
<Textarea {...rest} />
))(
{
flex: '1 0 0',
boxSizing: 'border-box',