Flutter更改textfield获取焦点失去焦点下划线的颜色

child: TextField(
controller: pwdController,
obscureText: true,
decoration: InputDecoration(
hintText: ‘请输入验证码’,
prefixIcon: Icon(Icons.lock),
enabledBorder: UnderlineInputBorder(
borderSide: BorderSide(color: Colors.orange),
),
focusedBorder: UnderlineInputBorder(
borderSide: BorderSide(color: Colors.red),
),
),
),

参考链接: link.

相关推荐
©️2020 CSDN 皮肤主题: 数字20 设计师:CSDN官方博客 返回首页