copyWith method
AppThemeExtension
copyWith({
- Color? primary,
- Color? secondary,
- Color? success,
- Color? error,
- Color? warning,
- Color? info,
- Gradient? brandGradient,
- Color? surface,
- AppBarStyle? appBarStyle,
override
Creates a copy of this theme extension with the given fields replaced by the non-null parameter values.
Implementation
@override
AppThemeExtension copyWith({
Color? primary,
Color? secondary,
Color? success,
Color? error,
Color? warning,
Color? info,
Gradient? brandGradient,
Color? surface,
AppBarStyle? appBarStyle,
}) =>
AppThemeExtension(
primary: primary ?? this.primary,
secondary: secondary ?? this.secondary,
success: success ?? this.success,
error: error ?? this.error,
warning: warning ?? this.warning,
info: info ?? this.info,
brandGradient: brandGradient ?? this.brandGradient,
surface: surface ?? this.surface,
appBarStyle: appBarStyle ?? this.appBarStyle,
);