The hintText attribute in InputDecoration seems doesn't work!
FormBuilderTextField(
name: 'name',
decoration: const InputDecoration(
labelText: 'Name',
border: InputBorder.none,
hintText: 'hint text',
filled: true,
),
validator: FormBuilderValidators.compose([
FormBuilderValidators.max(context, 8),
FormBuilderValidators.max(context, 24),
]),
);
Hi @bloodnwine,
Kindly note that hintText will only show when:
a. the labelText is either floating or empty
b. the field is empty.
If you need the hintText to always show, consider setting floatingLabelBehavior to FloatingLabelBehavior.always
Most helpful comment
Hi @bloodnwine,
Kindly note that
hintTextwill only show when:a. the
labelTextis either floating or emptyb. the field is empty.
If you need the
hintTextto always show, consider settingfloatingLabelBehaviortoFloatingLabelBehavior.always