From 3e10725e5803dd8cf42abd6bbbd4f10a14d92039 Mon Sep 17 00:00:00 2001 From: Paul Dempsey <76729591+paul-daniel-dempsey@users.noreply.github.com> Date: Thu, 30 Jan 2025 17:47:39 +0000 Subject: [PATCH] feat: benefits in ProductCopy --- support-frontend/assets/helpers/productCatalog.ts | 2 +- .../pages/subscriptions-landing/copy/subscriptionCopy.tsx | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/support-frontend/assets/helpers/productCatalog.ts b/support-frontend/assets/helpers/productCatalog.ts index bd14e10ef6..eb4bafa8ed 100644 --- a/support-frontend/assets/helpers/productCatalog.ts +++ b/support-frontend/assets/helpers/productCatalog.ts @@ -12,7 +12,7 @@ export type { ActiveProductKey }; export const productCatalog = window.guardian.productCatalog; -type ProductBenefit = { +export type ProductBenefit = { copy: string; tooltip?: string; specificToRegions?: CountryGroupId[]; diff --git a/support-frontend/assets/pages/subscriptions-landing/copy/subscriptionCopy.tsx b/support-frontend/assets/pages/subscriptions-landing/copy/subscriptionCopy.tsx index 9f49872891..940eac480b 100644 --- a/support-frontend/assets/pages/subscriptions-landing/copy/subscriptionCopy.tsx +++ b/support-frontend/assets/pages/subscriptions-landing/copy/subscriptionCopy.tsx @@ -8,6 +8,8 @@ import type { Participations } from 'helpers/abTests/abtest'; import type { CountryGroupId } from 'helpers/internationalisation/countryGroup'; import { GBPCountries } from 'helpers/internationalisation/countryGroup'; import { currencies, detect } from 'helpers/internationalisation/currency'; +import type { ProductBenefit } from 'helpers/productCatalog'; +import { productCatalogDescription } from 'helpers/productCatalog'; import type { BillingPeriod } from 'helpers/productPrice/billingPeriods'; import { Monthly } from 'helpers/productPrice/billingPeriods'; import { @@ -43,6 +45,7 @@ type ProductCopy = { buttons: ProductButton[]; classModifier?: string[]; participations?: Participations; + benefits?: ProductBenefit[]; }; const getDisplayPrice = ( @@ -115,6 +118,7 @@ function digitalCheckout( modifierClasses: 'digital', }, ], + benefits: productCatalogDescription['DigitalSubscription'].benefits, }; }