From 283d6e3781a058b12dde954c00826042ab700370 Mon Sep 17 00:00:00 2001 From: Vit Horacek <36083550+mountiny@users.noreply.github.com> Date: Fri, 19 Jul 2024 18:24:06 +0200 Subject: [PATCH] Merge pull request #45745 from bernhardoj/fix/45740-markdown-converted-to-html-in-ws-invite-page [CP Staging] Fix workspace description shows as HTML in workspace invite message page (cherry picked from commit f69f858f614933759591b1f4ede42e8ed0781e1f) --- src/pages/workspace/WorkspaceInviteMessagePage.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/pages/workspace/WorkspaceInviteMessagePage.tsx b/src/pages/workspace/WorkspaceInviteMessagePage.tsx index 2d420d0da3a9..877a77f62d3f 100644 --- a/src/pages/workspace/WorkspaceInviteMessagePage.tsx +++ b/src/pages/workspace/WorkspaceInviteMessagePage.tsx @@ -22,6 +22,7 @@ import useLocalize from '@hooks/useLocalize'; import useThemeStyles from '@hooks/useThemeStyles'; import Navigation from '@libs/Navigation/Navigation'; import * as OptionsListUtils from '@libs/OptionsListUtils'; +import Parser from '@libs/Parser'; import * as PolicyUtils from '@libs/PolicyUtils'; import updateMultilineInputRange from '@libs/updateMultilineInputRange'; import type {SettingsNavigatorParamList} from '@navigation/types'; @@ -83,7 +84,7 @@ function WorkspaceInviteMessagePage({ workspaceInviteMessageDraft || // policy?.description can be an empty string // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing - policy?.description || + Parser.htmlToMarkdown(policy?.description ?? '') || translate('workspace.common.welcomeNote', { workspaceName: policy?.name ?? '', });