CustomTextInput constructor

const CustomTextInput({
  1. Key? key,
  2. required TextEditingController controller,
  3. String? labelText,
  4. String? hintText,
  5. String? helperText,
  6. String? errorText,
  7. IconData? prefixIcon,
  8. IconData? suffixIcon,
  9. VoidCallback? onSuffixIconPressed,
  10. TextInputType keyboardType = TextInputType.text,
  11. bool obscureText = false,
  12. bool enabled = true,
  13. List<TextInputFormatter>? inputFormatters,
  14. int? maxLength,
  15. int? maxLines = 1,
  16. int? minLines,
  17. String? counterText,
  18. AutovalidateMode? autovalidateMode,
  19. String? validator(
    1. String?
    )?,
  20. void onChanged(
    1. String
    )?,
  21. void onSubmitted(
    1. String
    )?,
  22. double borderRadius = 8.0,
  23. EdgeInsetsGeometry contentPadding = const EdgeInsets.symmetric(horizontal: 16, vertical: 16),
  24. Color? fillColor,
  25. Color? borderColor,
  26. FocusNode? focusNode,
  27. bool autocorrect = false,
  28. TextCapitalization textCapitalization = TextCapitalization.none,
  29. TextInputAction? textInputAction,
  30. TextStyle? textStyle,
  31. String fontFamily = 'Roboto',
})

Implementation

const CustomTextInput({
  Key? key,
  required this.controller,
  this.labelText,
  this.hintText,
  this.helperText,
  this.errorText,
  this.prefixIcon,
  this.suffixIcon,
  this.onSuffixIconPressed,
  this.keyboardType = TextInputType.text,
  this.obscureText = false,
  this.enabled = true,
  this.inputFormatters,
  this.maxLength,
  this.maxLines = 1,
  this.minLines,
  this.counterText,
  this.autovalidateMode,
  this.validator,
  this.onChanged,
  this.onSubmitted,
  this.borderRadius = 8.0,
  this.contentPadding =
      const EdgeInsets.symmetric(horizontal: 16, vertical: 16),
  this.fillColor,
  this.borderColor,
  this.focusNode,
  this.autocorrect = false,
  this.textCapitalization = TextCapitalization.none,
  this.textInputAction,
  this.textStyle,
  this.fontFamily = 'Roboto',
}) : super(key: key);