From cf36bffe07bea8ee429c149c076059e8090dedc3 Mon Sep 17 00:00:00 2001
From: Peter Zimon <zimo@ghost.org>
Date: Tue, 17 Aug 2021 15:03:45 +0200
Subject: [PATCH] Fixed no-description bug

---
 ghost/portal/src/components/common/PlansSection.js    | 7 +++++--
 ghost/portal/src/components/common/ProductsSection.js | 2 +-
 ghost/portal/src/utils/fixtures.js                    | 3 ++-
 ghost/portal/src/utils/helpers.js                     | 2 +-
 4 files changed, 9 insertions(+), 5 deletions(-)

diff --git a/ghost/portal/src/components/common/PlansSection.js b/ghost/portal/src/components/common/PlansSection.js
index 1ffa7ca296..33e4dde92a 100644
--- a/ghost/portal/src/components/common/PlansSection.js
+++ b/ghost/portal/src/components/common/PlansSection.js
@@ -566,9 +566,12 @@ function PlanBenefits({product, plans, selectedPlan}) {
     });
     let planBenefits = [];
     let planDescription = product.description;
+    if (!product.description) {
+        planDescription = `Get full access to ` + site.title;
+    }
     if (selectedPlan === 'free') {
         planBenefits = [];
-        planDescription = `Free preview of ` + site.title;
+        planDescription = `Get a free preview of ` + site.title;
     } else if (plan?.interval === 'month') {
         planBenefits = productBenefits.monthly;
     } else if (plan?.interval === 'year') {
@@ -585,7 +588,7 @@ function PlanBenefits({product, plans, selectedPlan}) {
 
     return (
         <div className={'gh-portal-singleproduct-benefits gh-portal-product-benefits ' + benefitsClass}>
-            {(product.description ? <div className='gh-portal-product-description'> {planDescription} </div> : '')}
+            <div className='gh-portal-product-description'> {planDescription} </div>
             {benefits}
         </div>
     );
diff --git a/ghost/portal/src/components/common/ProductsSection.js b/ghost/portal/src/components/common/ProductsSection.js
index 0cbaa75e15..db787d3427 100644
--- a/ghost/portal/src/components/common/ProductsSection.js
+++ b/ghost/portal/src/components/common/ProductsSection.js
@@ -146,7 +146,7 @@ export const ProductsSectionStyles = ({site}) => {
             font-size: 1.35rem;
             line-height: 1.45em;
             text-align: center;
-            color: var(--grey5);
+            color: var(--grey3);
             margin-bottom: 24px;
         }
 
diff --git a/ghost/portal/src/utils/fixtures.js b/ghost/portal/src/utils/fixtures.js
index 698fb201e3..e9b1ec06f7 100644
--- a/ghost/portal/src/utils/fixtures.js
+++ b/ghost/portal/src/utils/fixtures.js
@@ -27,7 +27,7 @@ const products = [
     {
         id: 'product_1',
         name: 'Ball is life membership',
-        description: 'Get access to everything and lock in early adopter pricing for life + listen to my podcast',
+        description: '',
         monthlyPrice: {
             id: '6085adc776909b1a2382369a',
             stripe_price_id: '7d6c89c0289ca1731226e86b95b5a162085b8561ca0d10d3a4f03afd3e3e6ba6',
@@ -50,6 +50,7 @@ const products = [
             type: 'recurring',
             interval: 'year'
         },
+        // benefits: [],
         benefits: [
             {
                 id: 'a1',
diff --git a/ghost/portal/src/utils/helpers.js b/ghost/portal/src/utils/helpers.js
index 5e38b8f31e..ab5aec271d 100644
--- a/ghost/portal/src/utils/helpers.js
+++ b/ghost/portal/src/utils/helpers.js
@@ -258,7 +258,7 @@ export function getProductBenefits({product, site = null}) {
         const yearlyDiscount = calculateDiscount(product.monthlyPrice.amount, product.yearlyPrice.amount);
         const productBenefits = product?.benefits || [];
         const monthlyBenefits = product?.benefits?.length > 0 ? [...productBenefits] : [{
-            name: 'Full access to all articles'
+            name: 'Access to all articles'
         }];
         const yearlyBenefits = [...monthlyBenefits];
         if (yearlyDiscount > 0 && availablePrices.length > 1) {