copyWith method
ButtonConfig
copyWith(
{ - Color? backgroundColor,
- Color? textColor,
- double? fontSize,
- bool? enableGradient,
- double? borderRadius,
- EdgeInsetsGeometry? padding,
- Widget? icon,
- Widget? suffixIcon,
- double? borderWidth,
- Color? borderColor,
- List<Color>? gradientColors,
- Gradient? customGradient,
})
Implementation
ButtonConfig copyWith({
Color? backgroundColor,
Color? textColor,
double? fontSize,
bool? enableGradient,
double? borderRadius,
EdgeInsetsGeometry? padding,
Widget? icon,
Widget? suffixIcon,
double? borderWidth,
Color? borderColor,
List<Color>? gradientColors,
Gradient? customGradient,
}) {
return ButtonConfig(
backgroundColor: backgroundColor ?? this.backgroundColor,
textColor: textColor ?? this.textColor,
fontSize: fontSize ?? this.fontSize,
borderRadius: borderRadius ?? this.borderRadius,
padding: padding ?? this.padding,
borderWidth: borderWidth ?? this.borderWidth,
borderColor: borderColor ?? this.borderColor,
);
}