From 3e35e64906a3bab76c5e89436d90c41c58e22f85 Mon Sep 17 00:00:00 2001 From: powerwlsl Date: Tue, 9 Aug 2022 02:24:27 +0900 Subject: [PATCH] disable ratings and reviews if a provider is BC --- site/.env.template | 4 ++-- .../product/ProductSidebar/ProductSidebar.tsx | 11 +++++++---- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/site/.env.template b/site/.env.template index a9eb798fe..91880ee0b 100644 --- a/site/.env.template +++ b/site/.env.template @@ -21,7 +21,7 @@ BIGCOMMERCE_CHANNEL_ID= BIGCOMMERCE_STORE_URL= BIGCOMMERCE_STORE_API_STORE_HASH= BIGCOMMERCE_STORE_API_CLIENT_SECRET= - +NEXT_PUBLIC_IS_BC= NEXT_PUBLIC_SHOPIFY_STORE_DOMAIN= NEXT_PUBLIC_SHOPIFY_STOREFRONT_ACCESS_TOKEN= @@ -53,4 +53,4 @@ SFCC_CLIENT_ID= SFCC_CLIENT_SECRET= SFCC_ORG_ID= SFCC_SHORT_CODE= -SFCC_SITE_ID=RefArch \ No newline at end of file +SFCC_SITE_ID=RefArch diff --git a/site/components/product/ProductSidebar/ProductSidebar.tsx b/site/components/product/ProductSidebar/ProductSidebar.tsx index e549ed698..604811f82 100644 --- a/site/components/product/ProductSidebar/ProductSidebar.tsx +++ b/site/components/product/ProductSidebar/ProductSidebar.tsx @@ -52,10 +52,13 @@ const ProductSidebar: FC = ({ product, className }) => { className="pb-4 break-words w-full max-w-xl" html={product.descriptionHtml || product.description} /> -
- -
36 reviews
-
+ + {!process.env.NEXT_PUBLIC_IS_BC && +
+ +
36 reviews
+
+ }
{process.env.COMMERCE_CART_ENABLED && (