copyWith method

SnackbarStateConfig copyWith({
  1. Color? backgroundColor,
  2. Color? textColor,
  3. IconData? icon,
  4. Color? iconColor,
  5. double? iconSize,
  6. double? fontSize,
  7. FontWeight? fontWeight,
  8. BorderRadius? borderRadius,
  9. double? elevation,
  10. Color? shadowColor,
  11. bool? showIcon,
  12. Widget? customContent,
  13. SnackBarAction? action,
})

Copy with method for easy customization

Implementation

SnackbarStateConfig copyWith({
  Color? backgroundColor,
  Color? textColor,
  IconData? icon,
  Color? iconColor,
  double? iconSize,
  double? fontSize,
  FontWeight? fontWeight,
  BorderRadius? borderRadius,
  double? elevation,
  Color? shadowColor,
  bool? showIcon,
  Widget? customContent,
  SnackBarAction? action,
}) {
  return SnackbarStateConfig(
    backgroundColor: backgroundColor ?? this.backgroundColor,
    textColor: textColor ?? this.textColor,
    icon: icon ?? this.icon,
    iconColor: iconColor ?? this.iconColor,
    iconSize: iconSize ?? this.iconSize,
    fontSize: fontSize ?? this.fontSize,
    fontWeight: fontWeight ?? this.fontWeight,
    borderRadius: borderRadius ?? this.borderRadius,
    elevation: elevation ?? this.elevation,
    shadowColor: shadowColor ?? this.shadowColor,
    showIcon: showIcon ?? this.showIcon,
    customContent: customContent ?? this.customContent,
    action: action ?? this.action,
  );
}