From 35008202e80df34b15dc48012f26889c91b789fb Mon Sep 17 00:00:00 2001 From: Matthias Kretschmann Date: Mon, 11 Feb 2019 12:53:19 +0100 Subject: [PATCH] more input fixes --- src/components/atoms/Form/Input.tsx | 44 +++++++++++++++++++++++------ 1 file changed, 36 insertions(+), 8 deletions(-) diff --git a/src/components/atoms/Form/Input.tsx b/src/components/atoms/Form/Input.tsx index bb2dd28..d05b33c 100644 --- a/src/components/atoms/Form/Input.tsx +++ b/src/components/atoms/Form/Input.tsx @@ -48,12 +48,21 @@ export default class Input extends PureComponent { } public InputComponent = () => { - const { type, options, group, name } = this.props + const { type, options, group, name, required } = this.props + + const wrapClass = this.inputWrapClasses() if (type === 'select') { return ( -
- {options && options.map((option: string, index: number) => ( @@ -71,8 +80,14 @@ export default class Input extends PureComponent { ) } else if (type === 'textarea') { return ( -
-