Unable to type anything on the textarea
Answered
Jenn posted this in #help-forum
JennOP
I am using shadcn Textarea and I cannot type anything on it:
If I change the
<Label.Root htmlFor="Remarks" className="block text-sm font-medium leading-6 text-cyan-600">Remarks</Label.Root>
<Textarea placeholder="Type your message here."
id="remarks"
value={formValue && formValue.remarks ? formValue.remarks.toString() : ''}
onChange={(event) => setFormValue({ ...formValue, [event.target.name]: event.target.value })}
/>If I change the
textare to input , everything just works. const [formValue, setFormValue] = useState<WaterStationFormData>({
name: "",
//rest of the codes
remarks: null,
});
3 Replies
add this to
Textareaname="remarks"Answer
JennOP
Oh thank you. I was missing the "name"