CreditCardNumberField constructor

const CreditCardNumberField({
  1. String? labelPrefix,
  2. String? label,
  3. Widget? labelWidget,
  4. TextEditingController? controller,
  5. String? validator(
    1. String? value
    )?,
  6. bool obscureText = false,
  7. List<TextInputFormatter>? inputFormatter,
  8. TextAlign textAlign = TextAlign.start,
  9. void onSaved(
    1. String? value
    )?,
  10. String? initialValue,
  11. bool enabled = true,
  12. AutovalidateMode autoValidateMode = AutovalidateMode.disabled,
  13. ValueChanged<String?>? onChanged,
  14. FocusNode? focusNode,
  15. TextInputAction? textInputAction,
  16. ValueChanged<String?>? onFieldSubmitted,
  17. bool autocorrect = true,
  18. bool enableSuggestions = true,
  19. TextCapitalization textCapitalization = TextCapitalization.none,
  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. bool readOnly = false,
  27. TextStyle? style,
  28. InputDecoration? decoration,
  29. EdgeInsets padding = const EdgeInsets.all(8),
  30. String? hintText,
  31. EdgeInsets? contentPadding,
  32. String? counterText = '',
  33. Widget? prefix,
  34. Widget? prefixIcon,
  35. Widget? suffix,
  36. Widget? suffixIcon,
  37. bool trimOnSaved = true,
  38. dynamic onTypeChange(
    1. CreditCardType creditCardType
    )?,
  39. dynamic onValid(
    1. bool valid
    )?,
  40. String validatorMessage = 'Informe o número do cartão de crédito.',
  41. void onTap()?,
  42. int? sizeExtraSmall,
  43. int? sizeSmall,
  44. int? sizeMedium,
  45. int? sizeLarge,
  46. int? sizeExtraLarge,
  47. double? minHeight,
  48. Key? key,
})

Implementation

const CreditCardNumberField({
  this.labelPrefix,
  this.label,
  this.labelWidget,
  this.controller,
  this.validator,
  this.obscureText = false,
  this.inputFormatter,
  this.textAlign = TextAlign.start,
  this.onSaved,
  this.initialValue,
  this.enabled = true,
  this.autoValidateMode = AutovalidateMode.disabled,
  this.onChanged,
  this.focusNode,
  this.textInputAction,
  this.onFieldSubmitted,
  this.autocorrect = true,
  this.enableSuggestions = true,
  this.textCapitalization = TextCapitalization.none,
  this.scrollPadding = const EdgeInsets.all(20),
  this.enableInteractiveSelection = true,
  this.filled = false,
  this.fillColor,
  this.required = true,
  this.autofillHints,
  this.readOnly = false,
  this.style,
  this.decoration,
  this.padding = const EdgeInsets.all(8),
  this.hintText,
  this.contentPadding,
  this.counterText = '',
  this.prefix,
  this.prefixIcon,
  this.suffix,
  this.suffixIcon,
  this.trimOnSaved = true,
  this.onTypeChange,
  this.onValid,
  this.validatorMessage = 'Informe o número do cartão de crédito.',
  this.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.',
      );