diff --git a/plugins/harness-iacm/src/components/WorkspaceList/index.tsx b/plugins/harness-iacm/src/components/WorkspaceList/index.tsx index d5fa727..22d9a38 100644 --- a/plugins/harness-iacm/src/components/WorkspaceList/index.tsx +++ b/plugins/harness-iacm/src/components/WorkspaceList/index.tsx @@ -18,6 +18,7 @@ import useGetResources from '../../hooks/useGetResources'; import useProjectUrlSlugEntity from '../../hooks/useProjectUrlEntity'; import { useResourceSlugFromEntity } from './useResourceSlugFromEntity'; import ResourceTable from '../ResourceTable'; +import { EmptyState } from '@backstage/core-components'; const useStyles = makeStyles(theme => ({ container: { @@ -48,6 +49,12 @@ const useStyles = makeStyles(theme => ({ alignItems: 'center', gap: '5px', }, + noAccess: { + padding: theme.spacing(2), + display: 'flex', + + textAlign: 'center', + }, })); export interface Workspace { @@ -152,6 +159,16 @@ function WorkspaceList() { ) : null} ); + if (state === AsyncStatus.Unauthorized) { + return ( + + ); + } if (state === AsyncStatus.Init || state === AsyncStatus.Loading) { return (