diff --git a/app/containers/markdown/index.tsx b/app/containers/markdown/index.tsx index 27dc0ff37..ca8ce9271 100644 --- a/app/containers/markdown/index.tsx +++ b/app/containers/markdown/index.tsx @@ -45,6 +45,7 @@ interface IMarkdownProps { testID?: string; style?: StyleProp[]; onLinkPress?: TOnLinkPress; + isTranslated?: boolean; } type TLiteral = { @@ -93,9 +94,7 @@ class Markdown extends PureComponent { constructor(props: IMarkdownProps) { super(props); - if (!this.isNewMarkdown) { - this.renderer = this.createRenderer(); - } + this.renderer = this.createRenderer(); } createRenderer = () => @@ -310,13 +309,24 @@ class Markdown extends PureComponent { }; render() { - const { msg, md, mentions, channels, navToRoomInfo, useRealName, username = '', getCustomEmoji, onLinkPress } = this.props; + const { + msg, + md, + mentions, + channels, + navToRoomInfo, + useRealName, + username = '', + getCustomEmoji, + onLinkPress, + isTranslated + } = this.props; if (!msg) { return null; } - if (this.isNewMarkdown) { + if (this.isNewMarkdown && !isTranslated) { return ( ); } diff --git a/app/containers/message/index.tsx b/app/containers/message/index.tsx index 21d74de45..7c61c37f1 100644 --- a/app/containers/message/index.tsx +++ b/app/containers/message/index.tsx @@ -376,10 +376,13 @@ class MessageContainer extends React.Component ); diff --git a/app/containers/message/interfaces.ts b/app/containers/message/interfaces.ts index 9d0badb75..60edfb4df 100644 --- a/app/containers/message/interfaces.ts +++ b/app/containers/message/interfaces.ts @@ -63,6 +63,7 @@ export interface IMessageContent { comment?: string; hasError: boolean; isHeader: boolean; + isTranslated: boolean; } export interface IMessageEmoji {