copyWith method
- @useResult
- Color? backgroundColor,
- Color? foregroundColor,
- TextStyleDelta? textStyle,
- Duration? fadeInDuration,
Returns a copy of this FAvatarStyle with the given properties replaced.
See customizing widget styles.
Parameters
- FAvatarStyle.backgroundColor - The fallback's background color.
- FAvatarStyle.foregroundColor - The fallback's color.
- FAvatarStyle.textStyle - The text style for the fallback text.
- FAvatarStyle.fadeInDuration - Duration for the transition animation.
Implementation
@useResult
FAvatarStyle copyWith({
Color? backgroundColor,
Color? foregroundColor,
TextStyleDelta? textStyle,
Duration? fadeInDuration,
}) => .new(
backgroundColor: backgroundColor ?? this.backgroundColor,
foregroundColor: foregroundColor ?? this.foregroundColor,
textStyle: textStyle?.call(this.textStyle) ?? this.textStyle,
fadeInDuration: fadeInDuration ?? this.fadeInDuration,
);