PrimaryButton constructor
const
PrimaryButton({
- required String text,
- required VoidCallback? onPressed,
- Key? key,
- TextStyle style = Styles.s16WhiteW500,
- Size minimumSize = const Size.fromHeight(50),
- Color buttonColor = ColorName.blue,
- Color disabledColor = ColorName.grey,
- bool isEnabled = true,
- Widget? icon,
- BorderRadiusGeometry borderRadius = const BorderRadius.all(Radius.circular(10)),
- EdgeInsetsGeometry margin = EdgeInsets.zero,
Implementation
const PrimaryButton({
required this.text,
required this.onPressed,
super.key,
this.style = Styles.s16WhiteW500,
this.minimumSize = const Size.fromHeight(50),
this.buttonColor = ColorName.blue,
this.disabledColor = ColorName.grey,
this.isEnabled = true,
this.icon,
this.borderRadius = const BorderRadius.all(Radius.circular(10)),
this.margin = EdgeInsets.zero,
}) : _isOutlined = false,
borderSideWidth = 2;