copyWith method

ChatBubbleSettings copyWith({
  1. bool? showUserName,
  2. bool? showTimestamp,
  3. bool? showUserAvatar,
  4. DateFormat? timestampFormat,
  5. TextStyle? textStyle,
  6. TextStyle? headerTextStyle,
  7. Color? contentBackgroundColor,
  8. ShapeBorder? contentShape,
  9. double? widthFactor,
  10. Size? avatarSize,
  11. EdgeInsetsGeometry? padding,
  12. EdgeInsetsGeometry? contentPadding,
  13. EdgeInsetsGeometry? avatarPadding,
  14. EdgeInsetsGeometry? headerPadding,
  15. EdgeInsetsGeometry? footerPadding,
})

Implementation

ChatBubbleSettings copyWith({
  bool? showUserName,
  bool? showTimestamp,
  bool? showUserAvatar,
  DateFormat? timestampFormat,
  TextStyle? textStyle,
  TextStyle? headerTextStyle,
  Color? contentBackgroundColor,
  ShapeBorder? contentShape,
  double? widthFactor,
  Size? avatarSize,
  EdgeInsetsGeometry? padding,
  EdgeInsetsGeometry? contentPadding,
  EdgeInsetsGeometry? avatarPadding,
  EdgeInsetsGeometry? headerPadding,
  EdgeInsetsGeometry? footerPadding,
}) {
  return ChatBubbleSettings(
    showUserName: showUserName ?? this.showUserName,
    showTimestamp: showTimestamp ?? this.showTimestamp,
    showUserAvatar: showUserAvatar ?? this.showUserAvatar,
    timestampFormat: timestampFormat ?? this.timestampFormat,
    textStyle: textStyle ?? this.textStyle,
    headerTextStyle: headerTextStyle ?? this.headerTextStyle,
    contentBackgroundColor:
        contentBackgroundColor ?? this.contentBackgroundColor,
    contentShape: contentShape ?? this.contentShape,
    widthFactor: widthFactor ?? this.widthFactor,
    avatarSize: avatarSize ?? this.avatarSize,
    padding: padding ?? this.padding,
    contentPadding: contentPadding ?? this.contentPadding,
    avatarPadding: avatarPadding ?? this.avatarPadding,
    headerPadding: headerPadding ?? this.headerPadding,
    footerPadding: footerPadding ?? this.footerPadding,
  );
}