diff --git a/.changeset/early-boxes-work.md b/.changeset/early-boxes-work.md new file mode 100644 index 0000000000..11fc3ba134 --- /dev/null +++ b/.changeset/early-boxes-work.md @@ -0,0 +1,6 @@ +--- +'@backstage/plugin-catalog': patch +--- + +Header in EntityLayout should always be shown. +Monitoring the loading status caused flickering when the refresh() method of the Async Entity was invoked. diff --git a/plugins/catalog/src/alpha/components/EntityLayout/EntityLayout.tsx b/plugins/catalog/src/alpha/components/EntityLayout/EntityLayout.tsx index 8f5838d545..750c8567ee 100644 --- a/plugins/catalog/src/alpha/components/EntityLayout/EntityLayout.tsx +++ b/plugins/catalog/src/alpha/components/EntityLayout/EntityLayout.tsx @@ -102,21 +102,13 @@ export const EntityLayout = (props: EntityLayoutProps) => { UNSTABLE_contextMenuOptions, contextMenuItems, children, + header, NotFoundComponent, parentEntityRelations, } = props; const { kind } = useRouteRefParams(entityRouteRef); const { entity, loading, error } = useAsyncEntity(); - const header = props.header ?? ( - - ); - const routes = useElementFilter( children, elements => @@ -150,7 +142,14 @@ export const EntityLayout = (props: EntityLayoutProps) => { return ( - {!loading && header} + {header ?? ( + + )} {loading && }