Button constructor

const Button({
  1. Key? key,
  2. required void onTap(),
  3. bool enabled = true,
  4. String? text,
  5. required ButtonType buttonType,
  6. EdgeInsetsGeometry? padding = const EdgeInsets.symmetric(horizontal: 10, vertical: 10),
  7. EdgeInsetsGeometry? margin,
  8. required String heroTag,
  9. required Color background,
  10. required Color iconColor,
  11. required Color textColor,
})

Implementation

const Button({
  Key? key,
  required this.onTap,
  this.enabled=true,
  this.text,
  required this.buttonType,
  this.padding=const EdgeInsets.symmetric(horizontal: 10,vertical: 10),
  this.margin,
  required this.heroTag,
  required this.background,
  required this.iconColor,
  required this.textColor,
}) : super(key: key);