work on styles

This commit is contained in:
Thomas Ruoff
2021-02-21 23:12:32 +01:00
parent a86c9dc3f5
commit fb91b1cbc8
15 changed files with 116 additions and 133 deletions

View File

@@ -6,17 +6,31 @@ export default function TextAreaInput({
placeholder,
onchange,
value,
styles = '',
}: {
text: string
name: string
placeholder: string
onchange: (name: string, event: ChangeEvent<{ value: string }>) => void
value: string
styles?: string
}) {
return (
<label>
{text}
<textarea className={name} placeholder={placeholder} onChange={onchange.bind(null, name)} value={value} />
</label>
<div>
<label htmlFor={name} className="block text-sm font-medium text-gray-700">
{text}
</label>
<div className="mt-1">
<textarea
id="about"
name="about"
rows={10}
className={`shadow-sm focus:ring-indigo-500 focus:border-indigo-500 mt-1 block w-full sm:text-sm border-gray-300 rounded-md ${styles}`}
placeholder={placeholder}
onChange={onchange.bind(null, name)}
value={value}
></textarea>
</div>
</div>
)
}