diff --git a/src/pages/workspace/WorkspaceInvitePage.tsx b/src/pages/workspace/WorkspaceInvitePage.tsx index e3fcc07f8653..da04141db03c 100644 --- a/src/pages/workspace/WorkspaceInvitePage.tsx +++ b/src/pages/workspace/WorkspaceInvitePage.tsx @@ -74,7 +74,7 @@ function WorkspaceInvitePage({route, policy}: WorkspaceInvitePageProps) { ); }, [policy?.employeeList]); - const {searchTerm, setSearchTerm, availableOptions, selectedOptions, selectedOptionsForDisplay, toggleSelection, areOptionsInitialized} = useSearchSelector({ + const {searchTerm, setSearchTerm, availableOptions, selectedOptions, selectedOptionsForDisplay, toggleSelection, areOptionsInitialized, onListEndReached} = useSearchSelector({ selectionMode: CONST.SEARCH_SELECTOR.SELECTION_MODE_MULTI, searchContext: CONST.SEARCH_SELECTOR.SEARCH_CONTEXT_MEMBER_INVITE, includeUserToInvite: true, @@ -98,6 +98,14 @@ function WorkspaceInvitePage({route, policy}: WorkspaceInvitePageProps) { }); } + // Recent reports section + if (availableOptions.recentReports.length > 0) { + sectionsArr.push({ + title: translate('common.recents'), + data: availableOptions.recentReports, + }); + } + // Contacts section if (availableOptions.personalDetails.length > 0) { sectionsArr.push({ @@ -225,6 +233,7 @@ function WorkspaceInvitePage({route, policy}: WorkspaceInvitePageProps) { footerContent={footerContent} isLoadingNewOptions={!!isSearchingForReports} addBottomSafeAreaPadding + onEndReached={onListEndReached} />