MobilePhoneField constructor

MobilePhoneField({
  1. MobilePhoneValidator? mobilePhoneValidator,
  2. String validatorMessage = 'Informe o celular.',
  3. String? labelPrefix,
  4. String? label,
  5. Widget? labelWidget,
  6. TextEditingController? controller,
  7. String? validator(
    1. String? value
    )?,
  8. List<TextInputFormatter>? inputFormatter,
  9. TextAlign textAlign = TextAlign.start,
  10. void onSaved(
    1. String?
    )?,
  11. String? initialValue,
  12. bool enabled = true,
  13. AutovalidateMode autoValidateMode = AutovalidateMode.disabled,
  14. ValueChanged<String?>? onChanged,
  15. FocusNode? focusNode,
  16. TextInputAction? textInputAction,
  17. ValueChanged<String?>? onFieldSubmitted,
  18. bool autocorrect = false,
  19. bool enableSuggestions = true,
  20. EdgeInsets scrollPadding = const EdgeInsets.all(20),
  21. bool enableInteractiveSelection = true,
  22. bool filled = false,
  23. Color? fillColor,
  24. bool required = true,
  25. Iterable<String>? autofillHints,
  26. TextStyle? style,
  27. InputDecoration? decoration,
  28. EdgeInsets padding = const EdgeInsets.all(8),
  29. String? hintText,
  30. EdgeInsets? contentPadding,
  31. String? counterText = '',
  32. Widget? prefix,
  33. Widget? prefixIcon,
  34. Widget? suffix,
  35. Widget? suffixIcon,
  36. void onTap()?,
  37. int? sizeExtraSmall,
  38. int? sizeSmall,
  39. int? sizeMedium,
  40. int? sizeLarge,
  41. int? sizeExtraLarge,
  42. double? minHeight,
  43. Key? key,
})

Implementation

MobilePhoneField({
  MobilePhoneValidator? mobilePhoneValidator,
  super.validatorMessage = 'Informe o celular.',
  super.labelPrefix,
  super.label,
  super.labelWidget,
  super.controller,
  super.validator,
  super.inputFormatter,
  super.textAlign,
  super.onSaved,
  super.initialValue,
  super.enabled,
  super.autoValidateMode,
  super.onChanged,
  super.focusNode,
  super.textInputAction,
  super.onFieldSubmitted,
  super.autocorrect,
  super.enableSuggestions = true,
  super.scrollPadding,
  super.enableInteractiveSelection,
  super.filled,
  super.fillColor,
  super.required,
  super.autofillHints,
  super.style,
  super.decoration,
  super.padding,
  super.hintText,
  super.contentPadding,
  super.counterText,
  super.prefix,
  super.prefixIcon,
  super.suffix,
  super.suffixIcon,
  super.onTap,
  super.sizeExtraSmall,
  super.sizeSmall,
  super.sizeMedium,
  super.sizeLarge,
  super.sizeExtraLarge,
  super.minHeight,
  super.key,
})  : assert(
        initialValue == null || controller == null,
        'initialValue or controller must be null.',
      ),
      assert(
        label == null || labelWidget == null,
        'label or labelWidget must be null.',
      ),
      super(
        abstractValidator: mobilePhoneValidator ?? MobilePhoneValidator(),
        maxLength: 15,
        textCapitalization: TextCapitalization.none,
      );