From d44e387f51ec424b62ffb0541ce7a9d646f4226b Mon Sep 17 00:00:00 2001 From: juanmigdr Date: Mon, 23 Mar 2026 16:43:33 +0100 Subject: [PATCH 1/2] chore: add commas to PnL --- app/components/UI/AssetOverview/Price/Price.tsx | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/app/components/UI/AssetOverview/Price/Price.tsx b/app/components/UI/AssetOverview/Price/Price.tsx index 451adfadedb..a07e17be31c 100644 --- a/app/components/UI/AssetOverview/Price/Price.tsx +++ b/app/components/UI/AssetOverview/Price/Price.tsx @@ -8,7 +8,6 @@ import SkeletonPlaceholder from 'react-native-skeleton-placeholder'; import { strings } from '../../../../../locales/i18n'; import { useStyles } from '../../../../component-library/hooks'; import { toDateFormat } from '../../../../util/date'; -import { addCurrencySymbol } from '../../../../util/number'; import { formatPriceWithSubscriptNotation } from '../../Predict/utils/format'; import Text, { TextColor, @@ -129,8 +128,12 @@ const Price = ({ variant={TextVariant.BodyMDMedium} allowFontScaling={false} > - {diff > 0 ? '+' : ''} - {addCurrencySymbol(diff, currentCurrency, true)} ( + {diff > 0 ? '+' : diff < 0 ? '-' : ''} + {formatPriceWithSubscriptNotation( + Math.abs(diff), + currentCurrency, + )}{' '} + {'('} {diff > 0 ? '+' : ''} {diff === 0 ? '0' : ((diff / comparePrice) * 100).toFixed(2)} %){' '} From 4055c1013a21a15ca8ffa68805e0c77c0950f6b8 Mon Sep 17 00:00:00 2001 From: juanmigdr Date: Tue, 24 Mar 2026 10:27:37 +0100 Subject: [PATCH 2/2] chore: minor change --- app/components/UI/AssetOverview/Price/Price.tsx | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/app/components/UI/AssetOverview/Price/Price.tsx b/app/components/UI/AssetOverview/Price/Price.tsx index a07e17be31c..f8c09c7628a 100644 --- a/app/components/UI/AssetOverview/Price/Price.tsx +++ b/app/components/UI/AssetOverview/Price/Price.tsx @@ -8,6 +8,7 @@ import SkeletonPlaceholder from 'react-native-skeleton-placeholder'; import { strings } from '../../../../../locales/i18n'; import { useStyles } from '../../../../component-library/hooks'; import { toDateFormat } from '../../../../util/date'; +import { addCurrencySymbol } from '../../../../util/number'; import { formatPriceWithSubscriptNotation } from '../../Predict/utils/format'; import Text, { TextColor, @@ -129,10 +130,12 @@ const Price = ({ allowFontScaling={false} > {diff > 0 ? '+' : diff < 0 ? '-' : ''} - {formatPriceWithSubscriptNotation( - Math.abs(diff), - currentCurrency, - )}{' '} + {diff !== 0 + ? formatPriceWithSubscriptNotation( + Math.abs(diff), + currentCurrency, + ) + : addCurrencySymbol(0, currentCurrency, true)}{' '} {'('} {diff > 0 ? '+' : ''} {diff === 0 ? '0' : ((diff / comparePrice) * 100).toFixed(2)}