From 63cf8a76655a8c23c6e508880092b653c6df8e58 Mon Sep 17 00:00:00 2001 From: krishna2323 Date: Fri, 23 Aug 2024 19:11:51 +0530 Subject: [PATCH] fix: Search - Raw markdown symbols visible in search expense list. Signed-off-by: krishna2323 --- .../SelectionList/Search/TransactionListItemRow.tsx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/components/SelectionList/Search/TransactionListItemRow.tsx b/src/components/SelectionList/Search/TransactionListItemRow.tsx index be42642316b..64c5f6a768f 100644 --- a/src/components/SelectionList/Search/TransactionListItemRow.tsx +++ b/src/components/SelectionList/Search/TransactionListItemRow.tsx @@ -15,6 +15,7 @@ import useThemeStyles from '@hooks/useThemeStyles'; import useWindowDimensions from '@hooks/useWindowDimensions'; import * as CurrencyUtils from '@libs/CurrencyUtils'; import DateUtils from '@libs/DateUtils'; +import Parser from '@libs/Parser'; import StringUtils from '@libs/StringUtils'; import * as TransactionUtils from '@libs/TransactionUtils'; import tryResolveUrlFromApiRoot from '@libs/tryResolveUrlFromApiRoot'; @@ -126,9 +127,9 @@ function MerchantCell({transactionItem, showTooltip, isLargeScreenWidth}: Transa const description = TransactionUtils.getDescription(transactionItem); let merchantOrDescriptionToDisplay = transactionItem.formattedMerchant; if (!merchantOrDescriptionToDisplay && !isLargeScreenWidth) { - merchantOrDescriptionToDisplay = description; + merchantOrDescriptionToDisplay = Parser.htmlToText(Parser.replace(description)); } - let merchant = transactionItem.shouldShowMerchant ? merchantOrDescriptionToDisplay : description; + let merchant = transactionItem.shouldShowMerchant ? merchantOrDescriptionToDisplay : Parser.htmlToText(Parser.replace(description)); if (TransactionUtils.hasReceipt(transactionItem) && TransactionUtils.isReceiptBeingScanned(transactionItem) && transactionItem.shouldShowMerchant) { merchant = translate('iou.receiptStatusTitle');