fixed logic when to show empty search result (#1053)

fixes: #1040
This commit is contained in:
Erik Jan de Wit 2021-08-24 12:38:29 +02:00 committed by GitHub
parent 89870cafc2
commit 4d789f84e3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 4 deletions

View file

@ -110,7 +110,6 @@ export const ClientsSection = () => {
<DeleteConfirm />
<KeycloakDataTable
key={key}
emptyState={<> </>}
loader={loader}
isPaginated
ariaLabelKey="clients:clientList"

View file

@ -413,9 +413,9 @@ export function KeycloakDataTable<T>({
)}
{!loading &&
(!data || data.length === 0) &&
(search !== "" || !isSearching) &&
searchPlaceholderKey &&
!emptyState && (
search !== "" &&
!isSearching &&
searchPlaceholderKey && (
<ListEmptyState
hasIcon={true}
icon={icon}