Button constructor

const Button({
  1. Key? key,
  2. String? title,
  3. double width = 100,
  4. VoidCallback? onPressed,
  5. IconData? icon,
  6. bool isLoading = false,
  7. bool isDisabled = false,
  8. TextStyle? textStyle,
  9. ButtonType buttonType = ButtonType.primary,
  10. double? height,
  11. Color? secondaryColor,
  12. Color? primaryColor,
  13. Color? errorColor,
  14. Color? successColor,
})

Implementation

const Button({
  super.key,
  this.title,
  this.width = 100,
  this.onPressed,
  this.icon,
  this.isLoading = false,
  this.isDisabled = false,
  this.textStyle,
  this.buttonType = ButtonType.primary,
  this.height,
  this.secondaryColor,
  this.primaryColor,
  this.errorColor,
  this.successColor,
});