From 757dfc22161920c5865e28f2933740b008a4f83a Mon Sep 17 00:00:00 2001 From: FitseTLT Date: Mon, 17 Mar 2025 17:35:57 +0300 Subject: [PATCH 1/2] add submit contentType --- src/components/EmptySelectionListContent.tsx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/components/EmptySelectionListContent.tsx b/src/components/EmptySelectionListContent.tsx index 3e832c636771..523b42aaf240 100644 --- a/src/components/EmptySelectionListContent.tsx +++ b/src/components/EmptySelectionListContent.tsx @@ -15,7 +15,7 @@ type EmptySelectionListContentProps = { contentType: string; }; -const CONTENT_TYPES = [CONST.IOU.TYPE.CREATE]; +const CONTENT_TYPES = [CONST.IOU.TYPE.CREATE, CONST.IOU.TYPE.SUBMIT]; type ContentType = TupleToUnion; function isContentType(contentType: unknown): contentType is ContentType { @@ -29,8 +29,8 @@ function EmptySelectionListContent({contentType}: EmptySelectionListContentProps if (!isContentType(contentType)) { return null; } - - const EmptySubtitle = {translate(`emptyList.${contentType}.subtitleText`)}; + const createExpenseContentType = CONST.IOU.TYPE.CREATE; + const EmptySubtitle = {translate(`emptyList.${createExpenseContentType}.subtitleText`)}; return ( @@ -39,7 +39,7 @@ function EmptySelectionListContent({contentType}: EmptySelectionListContentProps icon={Illustrations.ToddWithPhones} iconWidth={variables.emptySelectionListIconWidth} iconHeight={variables.emptySelectionListIconHeight} - title={translate(`emptyList.${contentType}.title`)} + title={translate(`emptyList.${createExpenseContentType}.title`)} shouldShowLink={false} CustomSubtitle={EmptySubtitle} containerStyle={[styles.mb8, styles.ph15]} From cad9fa8e9ed74192b1a61e6504134b26c2379cbd Mon Sep 17 00:00:00 2001 From: FitseTLT Date: Mon, 17 Mar 2025 18:20:39 +0300 Subject: [PATCH 2/2] rename var --- src/components/EmptySelectionListContent.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/components/EmptySelectionListContent.tsx b/src/components/EmptySelectionListContent.tsx index 523b42aaf240..2c45dcb5c825 100644 --- a/src/components/EmptySelectionListContent.tsx +++ b/src/components/EmptySelectionListContent.tsx @@ -29,8 +29,8 @@ function EmptySelectionListContent({contentType}: EmptySelectionListContentProps if (!isContentType(contentType)) { return null; } - const createExpenseContentType = CONST.IOU.TYPE.CREATE; - const EmptySubtitle = {translate(`emptyList.${createExpenseContentType}.subtitleText`)}; + const translationKeyContentType = CONST.IOU.TYPE.CREATE; + const EmptySubtitle = {translate(`emptyList.${translationKeyContentType}.subtitleText`)}; return ( @@ -39,7 +39,7 @@ function EmptySelectionListContent({contentType}: EmptySelectionListContentProps icon={Illustrations.ToddWithPhones} iconWidth={variables.emptySelectionListIconWidth} iconHeight={variables.emptySelectionListIconHeight} - title={translate(`emptyList.${createExpenseContentType}.title`)} + title={translate(`emptyList.${translationKeyContentType}.title`)} shouldShowLink={false} CustomSubtitle={EmptySubtitle} containerStyle={[styles.mb8, styles.ph15]}