How to change the colour of line below TextField ,whenever a wrong input is made in Flutter?
507
Same can done with - decoration: InputDecoration
TextField(
decoration: InputDecoration(
errorStyle: TextStyle(fontSize: 20.0,color: Colors.orange),
focusedErrorBorder: OutlineInputBorder(borderSide: BorderSide(color:
Colors.orange)),
)
Author by
Ravi
Updated on December 08, 2022Comments
-
Ravi over 1 year
I want to change the color of the text input filed when a wrong value is entered, e.g an invalid email is entered then the TextField will become red and the line below text field also becomes red, I want to make it orange.
-
Nicolai Henriksen over 5 yearsThis is an iOS answer and a Flutter answer is requested.