From 8b534771d8ee99bf17bfd0fa86cd9918a8ada94a Mon Sep 17 00:00:00 2001 From: Rajat Dabade Date: Tue, 17 Dec 2024 18:57:32 +0530 Subject: [PATCH] Fix the comments link and markdown rendering issue --- webapp/src/components/cardDetail/comment.scss | 2 +- webapp/src/components/cardDetail/comment.tsx | 1 - webapp/src/webapp_globals.ts | 3 --- 3 files changed, 1 insertion(+), 5 deletions(-) diff --git a/webapp/src/components/cardDetail/comment.scss b/webapp/src/components/cardDetail/comment.scss index c58f1d3a..7f8c2a32 100644 --- a/webapp/src/components/cardDetail/comment.scss +++ b/webapp/src/components/cardDetail/comment.scss @@ -65,7 +65,7 @@ user-select: text; } - .comment-markdown { + .comment-markdown > * { white-space: pre-wrap; } } diff --git a/webapp/src/components/cardDetail/comment.tsx b/webapp/src/components/cardDetail/comment.tsx index f8aadc27..4975ee7d 100644 --- a/webapp/src/components/cardDetail/comment.tsx +++ b/webapp/src/components/cardDetail/comment.tsx @@ -44,7 +44,6 @@ const Comment: FC = (props: Props) => { const formattedText = {messageHtmlToComponent(formatText(comment.title, { - renderer: Utils.getMarkdownRenderer(), atMentions: true, team: selectedTeam, channelNamesMap, diff --git a/webapp/src/webapp_globals.ts b/webapp/src/webapp_globals.ts index 74f62eba..14d54b35 100644 --- a/webapp/src/webapp_globals.ts +++ b/webapp/src/webapp_globals.ts @@ -5,8 +5,6 @@ import {NameMappedObjects} from "mattermost-redux/types/utilities" import {Channel} from "mattermost-redux/types/channels" -import {Renderer} from "marked" - import {Team} from "./store/teams" @@ -14,7 +12,6 @@ type Options = { atMentions: boolean; team: Team | null; channelNamesMap: NameMappedObjects; - renderer: Renderer; } type Props = {