From b59807d221676060355e9a5f725e129ce2e1db49 Mon Sep 17 00:00:00 2001 From: "kasia.oczkowska" Date: Wed, 30 Oct 2024 12:45:24 +0000 Subject: [PATCH] feat: introduce fallback for title value in the BillingCard --- .../src/components/UsageDataInformation/index.ee.jsx | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/packages/web/src/components/UsageDataInformation/index.ee.jsx b/packages/web/src/components/UsageDataInformation/index.ee.jsx index 300c1482..d025d0a6 100644 --- a/packages/web/src/components/UsageDataInformation/index.ee.jsx +++ b/packages/web/src/components/UsageDataInformation/index.ee.jsx @@ -44,7 +44,7 @@ function BillingCard(props) { - {title} + {title || '---'} @@ -119,12 +119,12 @@ export default function UsageDataInformation() { text: 'Upgrade plan', }, nextBillAmount: { - title: '---', + title: null, action: null, text: null, }, nextBillDate: { - title: '---', + title: null, action: null, text: null, }, @@ -137,7 +137,9 @@ export default function UsageDataInformation() { text: formatMessage('usageDataInformation.cancelPlan'), }, nextBillAmount: { - title: `€${subscription?.nextBillAmount}`, + title: subscription?.nextBillAmount + ? `€${subscription?.nextBillAmount}` + : null, action: subscription?.updateUrl, text: formatMessage('usageDataInformation.updatePaymentMethod'), },