move empty state out of list (#17560)

fixes: keycloak/keycloak-ui#4561
This commit is contained in:
Erik Jan de Wit 2023-03-13 07:45:44 +01:00 committed by GitHub
parent 6d39c5336a
commit 4f4c850766
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -307,20 +307,20 @@ export const GroupPickerDialog = ({
</DataListItemRow>
</DataListItem>
))}
{groups.length === 0 && !isSearching && (
<ListEmptyState
hasIcon={false}
message={t("groups:moveGroupEmpty")}
instructions={t("groups:moveGroupEmptyInstructions")}
/>
)}
{groups.length === 0 && isSearching && (
<ListEmptyState
message={t("common:noSearchResults")}
instructions={t("common:noSearchResultsInstructions")}
/>
)}
</DataList>
{groups.length === 0 && !isSearching && (
<ListEmptyState
hasIcon={false}
message={t("groups:moveGroupEmpty")}
instructions={t("groups:moveGroupEmptyInstructions")}
/>
)}
{groups.length === 0 && isSearching && (
<ListEmptyState
message={t("common:noSearchResults")}
instructions={t("common:noSearchResultsInstructions")}
/>
)}
</PaginatingTableToolbar>
</Modal>
);