Update empty table formatting

Signed-off-by: Adam Harvey <adam.harvey@dxc.com>
This commit is contained in:
Adam Harvey
2021-02-23 11:29:31 -05:00
parent 440de45549
commit 80af0fb577
5 changed files with 41 additions and 21 deletions
@@ -26,6 +26,7 @@ import {
Progress,
WarningPanel,
} from '@backstage/core';
import { Typography } from '@material-ui/core';
import {
EntityTable,
useEntity,
@@ -71,11 +72,15 @@ export const ProvidedApisCard = ({ variant = 'gridItem' }: Props) => {
title="Provided APIs"
variant={variant}
emptyContent={
<div>
This {entity.kind.toLowerCase()} does not provide its own APIs.{' '}
<Link to="https://backstage.io/docs/features/software-catalog/descriptor-format#specprovidesapis-optional">
(Learn how to change this.)
</Link>
<div style={{ textAlign: 'center' }}>
<Typography variant="h6">
This {entity.kind.toLowerCase()} does not provide its own APIs.{' '}
</Typography>
<Typography variant="body2">
<Link to="https://backstage.io/docs/features/software-catalog/descriptor-format#specprovidesapis-optional">
Learn how to change this.
</Link>
</Typography>
</div>
}
columns={apiEntityColumns}
@@ -72,7 +72,7 @@ export const ProvidingComponentsCard = ({ variant = 'gridItem' }: Props) => {
variant={variant}
emptyContent={
<div style={{ textAlign: 'center' }}>
<Typography variant="h6">No component provides this API. </Typography>
<Typography variant="h6">No component provides this API.</Typography>
<Typography variant="body2">
<Link to="https://backstage.io/docs/features/software-catalog/descriptor-format#specprovidesapis-optional">
Learn how to change this.
@@ -22,6 +22,7 @@ import {
Progress,
WarningPanel,
} from '@backstage/core';
import { Typography } from '@material-ui/core';
import {
EntityTable,
useEntity,
@@ -73,11 +74,15 @@ export const HasComponentsCard = ({ variant = 'gridItem' }: Props) => {
title="Components"
variant={variant}
emptyContent={
<div>
No component is part of this system.{' '}
<Link to="https://backstage.io/docs/features/software-catalog/descriptor-format#kind-component">
(Learn how to add components.)
</Link>
<div style={{ textAlign: 'center' }}>
<Typography variant="h6">
No component is part of this system.
</Typography>
<Typography variant="body2">
<Link to="https://backstage.io/docs/features/software-catalog/descriptor-format#kind-component">
Learn how to change this.
</Link>
</Typography>
</div>
}
columns={columns}
@@ -22,6 +22,7 @@ import {
Progress,
WarningPanel,
} from '@backstage/core';
import { Typography } from '@material-ui/core';
import {
EntityTable,
useEntity,
@@ -73,11 +74,15 @@ export const HasSubcomponentsCard = ({ variant = 'gridItem' }: Props) => {
title="Subcomponents"
variant={variant}
emptyContent={
<div>
No subcomponent is part of this component.{' '}
<Link to="https://backstage.io/docs/features/software-catalog/descriptor-format#specsubcomponentof-optional">
(Learn how to add subcomponents.)
</Link>
<div style={{ textAlign: 'center' }}>
<Typography variant="h6">
No subcomponent is part of this component.
</Typography>
<Typography variant="body2">
<Link to="https://backstage.io/docs/features/software-catalog/descriptor-format#specsubcomponentof-optional">
Learn how to change this.
</Link>
</Typography>
</div>
}
columns={columns}
@@ -22,6 +22,7 @@ import {
Progress,
WarningPanel,
} from '@backstage/core';
import { Typography } from '@material-ui/core';
import {
EntityTable,
useEntity,
@@ -70,11 +71,15 @@ export const HasSystemsCard = ({ variant = 'gridItem' }: Props) => {
title="Systems"
variant={variant}
emptyContent={
<div>
No system is part of this domain.{' '}
<Link to="https://backstage.io/docs/features/software-catalog/descriptor-format#kind-system">
(Learn how to add systems.)
</Link>
<div style={{ textAlign: 'center' }}>
<Typography variant="h6">
No system is part of this domain.
</Typography>
<Typography variant="body2">
<Link to="https://backstage.io/docs/features/software-catalog/descriptor-format#kind-system">
Learn how to change this.
</Link>
</Typography>
</div>
}
columns={columns}