NumericInput constructor

const NumericInput({
  1. Key? key,
  2. String? label = 'Number',
  3. bool isRequired = false,
  4. int? characterLimit,
  5. InputControlType type = InputControlType.gray,
  6. NumberGroupingSystem groupingSystem = NumberGroupingSystem.international,
  7. bool allowDecimals = true,
  8. int? decimalPlaces,
  9. bool allowNegative = false,
  10. num? minValue,
  11. num? maxValue,
  12. IconData? leftIcon,
  13. Widget? leftIconWidget,
  14. String? prefix,
  15. Widget? prefixWidget,
  16. String placeholder = '0',
  17. num? initialValue,
  18. TextEditingController? controller,
  19. FocusNode? focusNode,
  20. String? suffix,
  21. Widget? suffixWidget,
  22. ButtonIconGhost? rightButton,
  23. bool isError = false,
  24. bool showErrorMessage = true,
  25. String errorMessage = 'Error Message',
  26. List<String>? errorMessages,
  27. Widget? errorIconWidget,
  28. bool enabled = true,
  29. bool readOnly = false,
  30. bool autofocus = false,
  31. ValueChanged<num?>? onNumberChanged,
  32. ValueChanged<String>? onChanged,
  33. ValueChanged<String>? onSubmitted,
  34. VoidCallback? onTap,
})

Creates a NumericInput instance.

Implementation

const NumericInput({
  super.key,
  this.label = 'Number',
  this.isRequired = false,
  this.characterLimit,
  this.type = InputControlType.gray,
  this.groupingSystem = NumberGroupingSystem.international,
  this.allowDecimals = true,
  this.decimalPlaces,
  this.allowNegative = false,
  this.minValue,
  this.maxValue,
  this.leftIcon,
  this.leftIconWidget,
  this.prefix,
  this.prefixWidget,
  this.placeholder = '0',
  this.initialValue,
  this.controller,
  this.focusNode,
  this.suffix,
  this.suffixWidget,
  this.rightButton,
  this.isError = false,
  this.showErrorMessage = true,
  this.errorMessage = 'Error Message',
  this.errorMessages,
  this.errorIconWidget,
  this.enabled = true,
  this.readOnly = false,
  this.autofocus = false,
  this.onNumberChanged,
  this.onChanged,
  this.onSubmitted,
  this.onTap,
});