YmSearchBar constructor
YmSearchBar({
- String text = "",
- String hint = "搜索",
- double borderRadius = 30.0,
- EdgeInsets margin = const EdgeInsets.only(top: 10.0, bottom: 10.0),
- EdgeInsets padding = const EdgeInsets.only(left: 12),
- Color splashColor = const Color(0xFFD6D6D6),
- FocusNode? focusNode,
- TextEditingController? controller,
- dynamic onSubmitted(
- String text
- dynamic onChanged(
- String text
- dynamic onBackCallback()?,
- Function? clearCallback,
- int inputKeyWordsLength = 20,
- double fontSize = 14,
- bool isShowBackButton = false,
- double width = 200,
- double height = 60,
Implementation
YmSearchBar(
{this.text = "",
this.hint = "搜索",
this.borderRadius = 30.0,
this.margin = const EdgeInsets.only(top: 10.0, bottom: 10.0),
this.padding = const EdgeInsets.only(left: 12),
this.splashColor = const Color(0xFFD6D6D6),
this.focusNode,
this.controller,
this.onSubmitted,
this.onChanged,
this.onBackCallback,
this.clearCallback,
this.inputKeyWordsLength = 20,
this.fontSize = 14,
this.isShowBackButton = false,
this.width = 200,
this.height = 60});