From e4da8cba0976ea83eafd86c7033b5bf2c2d406cd Mon Sep 17 00:00:00 2001 From: Gan Eng Chin Date: Fri, 10 Mar 2023 02:13:05 +0800 Subject: [PATCH] Display info message when there are no campaign types. --- .../CreateNewCampaignModal/CreateNewCampaignModal.tsx | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/plugins/woocommerce-admin/client/marketing/overview-multichannel/Campaigns/CreateNewCampaignModal/CreateNewCampaignModal.tsx b/plugins/woocommerce-admin/client/marketing/overview-multichannel/Campaigns/CreateNewCampaignModal/CreateNewCampaignModal.tsx index 3d3a0ce7c6a..2af7f9e6abb 100644 --- a/plugins/woocommerce-admin/client/marketing/overview-multichannel/Campaigns/CreateNewCampaignModal/CreateNewCampaignModal.tsx +++ b/plugins/woocommerce-admin/client/marketing/overview-multichannel/Campaigns/CreateNewCampaignModal/CreateNewCampaignModal.tsx @@ -60,10 +60,12 @@ export const CreateNewCampaignModal = ( props: CreateCampaignModalProps ) => { >
- { __( - 'Where would you like to promote your products?', - 'woocommerce' - ) } + { !! campaignTypes?.length + ? __( + 'Where would you like to promote your products?', + 'woocommerce' + ) + : __( 'No campaign types found.', 'woocommerce' ) }
{ campaignTypes?.map( ( el ) => (