Added dash when there is no data (#2576)

This commit is contained in:
Erik Jan de Wit 2022-05-09 12:42:11 +02:00 committed by GitHub
parent 24ec9fd60a
commit 58112be510
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -100,25 +100,23 @@ export const AuthorizationScopes = ({ clientId }: ScopesProps) => {
row, row,
}: { }: {
row: ExpandableScopeRepresentation; row: ExpandableScopeRepresentation;
}) => { }) => (
return ( <>
<> {row.resources?.[0]?.name ? row.resources[0]?.name : "—"}{" "}
{row.resources?.[0]?.name} <MoreLabel array={row.resources} /> <MoreLabel array={row.resources} />
</> </>
); );
};
const PermissionsRenderer = ({ const PermissionsRenderer = ({
row, row,
}: { }: {
row: ExpandableScopeRepresentation; row: ExpandableScopeRepresentation;
}) => { }) => (
return ( <>
<> {row.permissions?.[0]?.name ? row.permissions[0]?.name : "—"}{" "}
{row.permissions?.[0]?.name} <MoreLabel array={row.permissions} /> <MoreLabel array={row.permissions} />
</> </>
); );
};
if (!scopes) { if (!scopes) {
return <KeycloakSpinner />; return <KeycloakSpinner />;
@ -169,7 +167,7 @@ export const AuthorizationScopes = ({ clientId }: ScopesProps) => {
<Th /> <Th />
<Th>{t("common:name")}</Th> <Th>{t("common:name")}</Th>
<Th>{t("resources")}</Th> <Th>{t("resources")}</Th>
<Th>{t("permissions")}</Th> <Th>{t("common:permissions")}</Th>
<Th /> <Th />
<Th /> <Th />
</Tr> </Tr>