address PR feedback from Erik, remove user ID per Haley feedback

This commit is contained in:
jenny-s51 2021-02-25 10:17:42 -05:00
parent 1f379e70eb
commit eca3bb8e71
3 changed files with 4 additions and 7 deletions

View file

@ -107,8 +107,8 @@ describe("Realm roles test", function () {
cy.contains("Users in role") cy.contains("Users in role")
.click() .click()
.get("#users-empty-state > div > h4") .get('[data-test-id="users-page"]')
.contains("No direct users"); .should('exist')
}); });
}); });
}); });

View file

@ -18,7 +18,6 @@ export type Action = {
}; };
export type ListEmptyStateProps = { export type ListEmptyStateProps = {
id?: string;
message: string; message: string;
instructions: string; instructions: string;
primaryActionText?: string; primaryActionText?: string;
@ -29,7 +28,6 @@ export type ListEmptyStateProps = {
}; };
export const ListEmptyState = ({ export const ListEmptyState = ({
id,
message, message,
instructions, instructions,
onPrimaryAction, onPrimaryAction,
@ -40,7 +38,7 @@ export const ListEmptyState = ({
}: ListEmptyStateProps) => { }: ListEmptyStateProps) => {
return ( return (
<> <>
<EmptyState id={id} variant="large"> <EmptyState variant="large">
{hasIcon && isSearchVariant ? ( {hasIcon && isSearchVariant ? (
<EmptyStateIcon icon={SearchIcon} /> <EmptyStateIcon icon={SearchIcon} />
) : ( ) : (

View file

@ -32,13 +32,12 @@ export const UsersInRoleTab = () => {
return ( return (
<> <>
<PageSection variant="light"> <PageSection data-test-id="users-page" variant="light">
{users.length == 0 ? ( {users.length == 0 ? (
<ListEmptyState <ListEmptyState
hasIcon={true} hasIcon={true}
message={t("noDirectUsers")} message={t("noDirectUsers")}
instructions={t("noUsersEmptyStateDescription")} instructions={t("noUsersEmptyStateDescription")}
id="users-empty-state"
/> />
) : ( ) : (
<KeycloakDataTable <KeycloakDataTable