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 69e26bbfe2..7006e78f05 100644 --- a/apps/admin-x-settings/src/components/settings/growth/Offers.tsx +++ b/apps/admin-x-settings/src/components/settings/growth/Offers.tsx @@ -11,11 +11,11 @@ import {useRouting} from '@tryghost/admin-x-framework/routing'; const OfferContainer: React.FC<{offerTitle: string, tier: Tier, cadence: string, redemptions: number, type: string, amount: number, currency: string, offerId: string, offerCode: string, goToOfferEdit: (offerId: string) => void}> = ( {offerTitle, tier, cadence, redemptions, type, amount, currency, offerId, offerCode, goToOfferEdit}) => { - const {discountColor, discountOffer} = getOfferDiscount(type, amount, cadence, currency || 'USD', tier); + const {discountOffer} = getOfferDiscount(type, amount, cadence, currency || 'USD', tier); return
goToOfferEdit(offerId)}> {offerTitle}
- {discountOffer} + {discountOffer}
{tier.name} {cadence === 'month' ? 'monthly' : 'yearly'} diff --git a/apps/admin-x-settings/src/components/settings/growth/offers/OffersIndex.tsx b/apps/admin-x-settings/src/components/settings/growth/offers/OffersIndex.tsx index 294d83d48b..b581bef775 100644 --- a/apps/admin-x-settings/src/components/settings/growth/offers/OffersIndex.tsx +++ b/apps/admin-x-settings/src/components/settings/growth/offers/OffersIndex.tsx @@ -176,13 +176,13 @@ export const OffersIndexModal = () => { const isTierArchived = offerTier?.active === false; - const {discountColor, discountOffer, originalPriceWithCurrency, updatedPriceWithCurrency} = getOfferDiscount(offer.type, offer.amount, offer.cadence, offer.currency || 'USD', offerTier); + const {discountOffer, originalPriceWithCurrency, updatedPriceWithCurrency} = getOfferDiscount(offer.type, offer.amount, offer.cadence, offer.currency || 'USD', offerTier); return ( handleOfferEdit(offer?.id ? offer.id : '') : () => {}}>{offer?.name}
{offerTier.name} {getOfferCadence(offer.cadence)}
- handleOfferEdit(offer?.id ? offer.id : '') : () => {}}>{discountOffer}{offer.type !== 'trial' ? <>
{getOfferDuration(offer.duration)} : null}
- handleOfferEdit(offer?.id ? offer.id : '') : () => {}}>{updatedPriceWithCurrency} {originalPriceWithCurrency} + handleOfferEdit(offer?.id ? offer.id : '') : () => {}}>{discountOffer}
{offer.type !== 'trial' ? getOfferDuration(offer.duration) : 'Trial period'}
+ handleOfferEdit(offer?.id ? offer.id : '') : () => {}}>{updatedPriceWithCurrency} {offer.type !== 'trial' ? {originalPriceWithCurrency} : null} 0 ? createRedemptionFilterUrl(offer.id ? offer.id : '') : undefined} onClick={offer.redemption_count === 0 ? !isTierArchived ? () => handleOfferEdit(offer?.id ? offer.id : '') : () => {} : () => {}}>{offer.redemption_count} {!isTierArchived ? : null} {isTierArchived ?