ExTextField constructor
const
ExTextField({
- Key? key,
- TextEditingController? controller,
- String? hint,
- String? value,
- bool clear = true,
- bool isPassword = false,
- bool obscureText = false,
- ExTextFieldBorderType borderType = ExTextFieldBorderType.underLine,
- int? maxLine = 1,
- int? maxLength,
- TextAlign textAlign = TextAlign.left,
- Color? fillColor = Colors.transparent,
- Color? borderColor = const Color(0xFFC7CBCF),
- Widget? prefixIcon,
- Widget? suffixIcon,
- double height = 40,
- double? borderRadius = 8,
- double? contentPaddingLeft = 12,
- double? contentPaddingRight,
- double? contentPaddingTop,
- TextInputType? keyboardType,
- TextInputAction? textInputAction,
- List<
TextInputFormatter> ? inputFormatters, - ValueChanged<
String> ? onChanged, - ValueChanged<
String> ? onSubmitted, - VoidCallback? onEditingComplete,
- FocusNode? focusNode,
- String? counterText,
- bool autofocus = false,
- TextStyle? style,
- String? labelText,
- TextStyle? labelStyle = const TextStyle(fontSize: 14),
- String? helperText,
- TextStyle? helperStyle = const TextStyle(fontSize: 12),
- Color? cursorColor,
- bool autocorrect = true,
- double? cursorHeight,
- Radius? cursorRadius,
- double cursorWidth = 2.0,
- bool enableSuggestions = true,
- bool? enabled,
- bool? showCursor,
- dynamic onSaved()?,
- String? validator()?,
- AutovalidateMode? autovalidateMode,
- Color? borderColorFocus,
- String? initialValue,
- bool? readOnly,
- bool? isRequired,
- Function? clearCallback,
Implementation
const ExTextField({
super.key,
this.controller,
this.hint,
this.value,
this.clear = true,
this.isPassword = false,
this.obscureText = false,
this.borderType = ExTextFieldBorderType.underLine,
this.maxLine = 1,
this.maxLength,
this.textAlign = TextAlign.left,
this.fillColor = Colors.transparent,
this.borderColor = const Color(0xFFC7CBCF),
this.prefixIcon,
this.suffixIcon,
this.height = 40,
this.borderRadius = 8,
this.contentPaddingLeft = 12,
this.contentPaddingRight,
this.contentPaddingTop,
this.keyboardType,
this.textInputAction,
this.inputFormatters,
this.onChanged,
this.onSubmitted,
this.onEditingComplete,
this.focusNode,
this.counterText,
this.autofocus = false,
this.style,
this.labelText,
this.labelStyle = const TextStyle(fontSize: 14),
this.helperText,
this.helperStyle = const TextStyle(fontSize: 12),
this.cursorColor,
this.autocorrect = true,
this.cursorHeight,
this.cursorRadius,
this.cursorWidth = 2.0,
this.enableSuggestions = true,
this.enabled,
this.showCursor,
this.onSaved,
this.validator,
this.autovalidateMode,
this.borderColorFocus,
this.initialValue,
this.readOnly,
this.isRequired,
this.clearCallback,
});