如何在Flutter的TextFormField中添加提示?

问题描述 投票:-3回答:2

我具有使用TextFormField的文本字段的以下代码。但是我没有在TextFormField中看到函数的任何属性,就像我们以前在Android的TextField中看到的那样添加标签或提示一样。如何添加?

enter image description here

android flutter text dart hint
2个回答
0
投票

提示由于其直接可用的属性或功能不可用,但它位于您可以在菜单中选择的装饰下。在其下可以找到标签和提示。

enter image description here


0
投票

装饰:InputDecoration(hintText:“您的提示”)

© www.soinside.com 2019 - 2024. All rights reserved.