diff --git a/.changeset/hide-compat-wrapper-headers.md b/.changeset/hide-compat-wrapper-headers.md new file mode 100644 index 0000000000..78b8f869d9 --- /dev/null +++ b/.changeset/hide-compat-wrapper-headers.md @@ -0,0 +1,5 @@ +--- +'@backstage/core-compat-api': patch +--- + +Hide the default page header for pages created through the compatibility wrappers, since legacy plugins already render their own headers. diff --git a/packages/core-compat-api/src/collectLegacyRoutes.tsx b/packages/core-compat-api/src/collectLegacyRoutes.tsx index 847964e86f..22ac4c607a 100644 --- a/packages/core-compat-api/src/collectLegacyRoutes.tsx +++ b/packages/core-compat-api/src/collectLegacyRoutes.tsx @@ -236,6 +236,7 @@ export function collectLegacyRoutes( // todo(blam): why do we not use the inputs here? return originalFactory({ path: normalizeRoutePath(path), + noHeader: true, routeRef: routeRef ? convertLegacyRouteRef(routeRef) : undefined, loader: async () => compatWrapper( diff --git a/packages/core-compat-api/src/convertLegacyPageExtension.tsx b/packages/core-compat-api/src/convertLegacyPageExtension.tsx index 299fcab58f..f0efc89f8e 100644 --- a/packages/core-compat-api/src/convertLegacyPageExtension.tsx +++ b/packages/core-compat-api/src/convertLegacyPageExtension.tsx @@ -60,6 +60,7 @@ export function convertLegacyPageExtension( name: overrides?.name ?? kebabName, params: { path: overrides?.path ?? `/${kebabName}`, + noHeader: true, routeRef: mountPoint && convertLegacyRouteRef(mountPoint), loader: async () => compatWrapper(element), },