return progress bar instead of null

Signed-off-by: Shijun Wang <shijun@shijun.dev>
This commit is contained in:
Shijun Wang
2025-09-09 08:33:25 +03:00
parent 929c55adbc
commit a2be46e16b
2 changed files with 7 additions and 4 deletions
+1 -1
View File
@@ -84,7 +84,7 @@ export const createCardExtension: typeof createCardExtension_2;
// @public
export const CustomHomepageGrid: (
props: CustomHomepageGridProps,
) => JSX_2.Element | null;
) => JSX_2.Element;
// @public
export type CustomHomepageGridProps = {
@@ -34,7 +34,11 @@ import {
} from '@material-ui/core/styles';
import { compact } from 'lodash';
import useObservable from 'react-use/esm/useObservable';
import { ContentHeader, ErrorBoundary } from '@backstage/core-components';
import {
ContentHeader,
ErrorBoundary,
Progress,
} from '@backstage/core-components';
import Typography from '@material-ui/core/Typography';
import { WidgetSettingsOverlay } from './WidgetSettingsOverlay';
import { AddWidgetDialog } from './AddWidgetDialog';
@@ -325,9 +329,8 @@ export const CustomHomepageGrid = (props: CustomHomepageGridProps) => {
);
};
// Don't render anything while storage is loading
if (isStorageLoading) {
return null;
return <Progress />;
}
return (