copyWith method
Creates a copy of this suggestion with the given fields replaced by the new values.
Implementation
ChatMessageSuggestion copyWith({
String? data,
bool? selected,
WidgetBuilder? builder,
}) {
if (builder != null) {
return ChatMessageSuggestion.builder(
builder: builder,
selected: selected ?? this.selected,
);
} else {
return ChatMessageSuggestion(
data: data ?? this.data,
selected: selected ?? this.selected,
);
}
}