From f00b342e83782275a8514cd576512677821a78db Mon Sep 17 00:00:00 2001 From: Sodbileg Gansukh Date: Wed, 13 Dec 2023 22:38:53 +0700 Subject: [PATCH] Fixed number formatting of offer redemptions count (#19365) fixes PROD-274 - corrected plural form of the label - added number formatting --- .../admin-x-settings/src/components/settings/growth/Offers.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/apps/admin-x-settings/src/components/settings/growth/Offers.tsx b/apps/admin-x-settings/src/components/settings/growth/Offers.tsx index 30a1824e78..c909c28ba1 100644 --- a/apps/admin-x-settings/src/components/settings/growth/Offers.tsx +++ b/apps/admin-x-settings/src/components/settings/growth/Offers.tsx @@ -5,6 +5,7 @@ import {CopyLinkButton, createRedemptionFilterUrl, getOfferDiscount} from './off import {Offer, useBrowseOffers} from '@tryghost/admin-x-framework/api/offers'; import {Tier, getPaidActiveTiers, useBrowseTiers} from '@tryghost/admin-x-framework/api/tiers'; import {checkStripeEnabled} from '@tryghost/admin-x-framework/api/settings'; +import {numberWithCommas} from '../../../utils/helpers'; import {useGlobalData} from '../../providers/GlobalDataProvider'; import {useRouting} from '@tryghost/admin-x-framework/routing'; @@ -20,7 +21,7 @@ const OfferContainer: React.FC<{offerTitle: string, tier: Tier, cadence: string, {cadence === 'month' ? 'monthly' : 'yearly'}
- {redemptions} redemptions + {numberWithCommas(redemptions)} {redemptions === 1 ? 'redemption' : 'redemptions'}