merge method
Merges this theme with another, preferring values from the other theme when they exist
Implementation
ChatTheme merge(ChatTheme? other) {
if (other == null) return this;
return ChatTheme(
userBubbleColor: other.userBubbleColor ?? userBubbleColor,
botBubbleColor: other.botBubbleColor ?? botBubbleColor,
userTextStyle: other.userTextStyle ?? userTextStyle,
botTextStyle: other.botTextStyle ?? botTextStyle,
userBubbleDecoration: other.userBubbleDecoration ?? userBubbleDecoration,
botBubbleDecoration: other.botBubbleDecoration ?? botBubbleDecoration,
inputDecoration: other.inputDecoration ?? inputDecoration,
sendButtonColor: other.sendButtonColor ?? sendButtonColor,
sendButtonDisabledColor:
other.sendButtonDisabledColor ?? sendButtonDisabledColor,
loadingIndicatorColor:
other.loadingIndicatorColor ?? loadingIndicatorColor,
backgroundColor: other.backgroundColor ?? backgroundColor,
userBubbleBorderRadius:
other.userBubbleBorderRadius ?? userBubbleBorderRadius,
botBubbleBorderRadius:
other.botBubbleBorderRadius ?? botBubbleBorderRadius,
);
}