NsgButton constructor

const NsgButton({
  1. Key? key,
  2. bool autoWidth = false,
  3. String? style,
  4. String? text = '',
  5. EdgeInsets? margin,
  6. EdgeInsets iconMargin = const EdgeInsets.fromLTRB(0, 0, 5, 0),
  7. IconData? icon,
  8. Color? iconColor,
  9. VoidCallback? onPressed,
  10. VoidCallback? onTap,
  11. Future<bool> onTapAsync()?,
  12. VoidCallback? onAfterTapAsync,
  13. VoidCallback? onDisabledPressed,
  14. bool? disabled,
  15. double? borderRadius,
  16. double? width,
  17. double? height,
  18. EdgeInsets padding = const EdgeInsets.symmetric(horizontal: 10, vertical: 2),
  19. Color? color,
  20. Color? borderColor,
  21. Color? backColor,
  22. Color? backHoverColor,
  23. double? fontSize,
  24. FontWeight? fontWeight,
  25. Widget? widget,
  26. BoxShadow? shadow,
})

Implementation

const NsgButton(
    {Key? key,
    this.autoWidth = false,
    this.style,
    this.text = '',
    this.margin,
    this.iconMargin = const EdgeInsets.fromLTRB(0, 0, 5, 0),
    this.icon,
    this.iconColor,
    this.onPressed,
    this.onTap,
    this.onTapAsync,
    this.onAfterTapAsync,
    this.onDisabledPressed,
    this.disabled,
    this.borderRadius,
    this.width,
    this.height,
    this.padding = const EdgeInsets.symmetric(horizontal: 10, vertical: 2),
    this.color,
    this.borderColor,
    this.backColor,
    this.backHoverColor,
    this.fontSize,
    this.fontWeight,
    this.widget,
    this.shadow})
    : super(key: key);