ContainedButton.text constructor
ContainedButton.text(
- String text, {
- Key? key,
- WidgetStateProperty<
Color?> ? color, - GBButtonGradient? gradient,
- double? minWidth,
- double? height,
- bool uppercase = true,
- bool busy = false,
- Color? busyColor,
- required VoidCallback? onPressed,
- Duration? loadingDebounce,
- BorderRadius? borderRadius,
- bool guessTextColor = true,
- EdgeInsets? padding,
- bool disabled = false,
- ButtonStyle? style,
Implementation
factory ContainedButton.text(
String text, {
Key? key,
WidgetStateProperty<Color?>? color,
GBButtonGradient? gradient,
double? minWidth,
double? height,
bool uppercase = true,
bool busy = false,
Color? busyColor,
required VoidCallback? onPressed,
Duration? loadingDebounce,
BorderRadius? borderRadius,
bool guessTextColor = true,
EdgeInsets? padding,
bool disabled = false,
ButtonStyle? style,
}) {
return ContainedButton(
key: key,
color: color,
gradient: gradient,
minWidth: minWidth,
height: height,
onPressed: onPressed,
busy: busy,
busyColor: busyColor,
loadingDebounce: loadingDebounce,
borderRadius: borderRadius,
guessTextColor: guessTextColor,
padding: padding,
disabled: disabled,
style: style,
child: Text(uppercase ? text.toUpperCase() : text),
);
}