CustomTextField constructor

const CustomTextField({
  1. Key? key,
  2. required String title,
  3. String? iconName,
  4. dynamic onChange(
    1. String v
    )?,
  5. String? trailingIconName,
  6. Widget? trailingIconWidget,
  7. Color? color,
  8. Color? borderColor,
  9. EdgeInsets? padding,
  10. Color? trailingIconColor,
  11. bool autoFocus = false,
  12. TextEditingController? controller,
  13. TextInputType? keyboardType,
  14. bool password = false,
  15. VoidCallback? handleShowPassword,
  16. TextInputAction? textInputAction,
  17. String? errorText,
  18. String? validator(
    1. String? v
    )?,
  19. bool enabled = true,
  20. TextStyle? textStyle,
  21. TextStyle? hintStyle,
  22. bool? requiredField,
  23. BorderRadius? borderRadius,
  24. int? maxLines,
  25. int? minLines,
  26. String? initialValue,
  27. Widget? trailingIcon,
  28. int? maxLength,
  29. BoxDecoration? decoration,
  30. dynamic onSubmitted(
    1. String v
    )?,
  31. Color? backgroundColor,
  32. Widget? leadingIcon,
  33. bool? obscureText,
  34. FocusNode? focusNode,
  35. List<TextInputFormatter>? inputFormatters,
  36. CrossAxisAlignment? crossAxisAlignment,
  37. InputDecoration? inputDecoration,
  38. Widget? buildCounter(
    1. BuildContext, {
    2. required int currentLength,
    3. required bool isFocused,
    4. required int? maxLength,
    })?,
})

Implementation

const CustomTextField({
  Key? key,
  required this.title,
  this.iconName,
  this.onChange,
  this.trailingIconName,
  this.trailingIconWidget,
  this.color,
  this.borderColor,
  this.padding,
  this.trailingIconColor,
  this.autoFocus = false,
  this.controller,
  this.keyboardType,
  this.password = false,
  this.handleShowPassword,
  this.textInputAction,
  this.errorText,
  this.validator,
  this.enabled = true,
  this.textStyle,
  this.hintStyle,
  this.requiredField,
  this.borderRadius,
  this.maxLines,
  this.minLines,
  this.initialValue,
  this.trailingIcon,
  this.maxLength,
  this.decoration,
  this.onSubmitted,
  this.backgroundColor,
  this.leadingIcon,
  this.obscureText,
  this.focusNode,
  this.inputFormatters,
  this.crossAxisAlignment,
  this.inputDecoration,
  this.buildCounter,
}) : super(key: key);