VButton constructor

const VButton({
  1. Key? key,
  2. String text = '',
  3. String? textColor,
  4. String? bgColor,
  5. String? disabledBgColor,
  6. String? imageBg,
  7. bool hasBorder = false,
  8. TextStyle? textStyle,
  9. BorderRadius? radius,
  10. Widget? child,
  11. double? width,
  12. Color? color,
  13. Color? highlightColor,
  14. Color? splashColor,
  15. Gradient? gradient,
  16. BoxBorder? border,
  17. EdgeInsets? padding,
  18. EdgeInsets margin = EdgeInsets.zero,
  19. String? textColorStr,
  20. VButtonType type = VButtonType.primary,
  21. bool block = false,
  22. bool round = false,
  23. bool disabled = false,
  24. bool loading = false,
  25. VLoadingType loadingType = VLoadingType.circular,
  26. Color? loadingColor,
  27. Widget? icon,
  28. VIconPosition iconPosition = VIconPosition.left,
  29. double? height,
  30. double? fontSize,
  31. VoidCallback? onPressed,
})

Implementation

const VButton({
  super.key,
  this.text = '',
  this.textColor,
  this.bgColor,
  this.disabledBgColor,
  this.imageBg,
  this.hasBorder = false,
  this.textStyle,
  this.radius,
  this.child,
  this.width,
  this.color,
  this.highlightColor,
  this.splashColor,
  this.gradient,
  this.border,
  this.padding,
  this.margin = EdgeInsets.zero,
  this.textColorStr,
  this.type = VButtonType.primary,
  this.block = false,
  this.round = false,
  this.disabled = false,
  this.loading = false,
  this.loadingType = VLoadingType.circular,
  this.loadingColor,
  this.icon,
  this.iconPosition = VIconPosition.left,
  this.height,
  this.fontSize,
  this.onPressed,
});