From 462c1d012e8e35bf86daefbe6f8850b4ea1b974f Mon Sep 17 00:00:00 2001 From: Luca Huettner Date: Wed, 30 Nov 2022 15:11:25 +0100 Subject: [PATCH 1/6] refactor: Remove the header from the default catalog page Signed-off-by: Luca Huettner --- .changeset/modern-camels-cheat.md | 5 ++++ .../CatalogKindHeader/CatalogKindHeader.tsx | 5 +++- .../CatalogPage/DefaultCatalogPage.tsx | 25 ++++++++----------- 3 files changed, 20 insertions(+), 15 deletions(-) create mode 100644 .changeset/modern-camels-cheat.md diff --git a/.changeset/modern-camels-cheat.md b/.changeset/modern-camels-cheat.md new file mode 100644 index 0000000000..69c680b989 --- /dev/null +++ b/.changeset/modern-camels-cheat.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-catalog': patch +--- + +Remove `CatalogKindHeader` from `DefaultCatalogPage`. Deprecate `CatalogKindHeader`. diff --git a/plugins/catalog/src/components/CatalogKindHeader/CatalogKindHeader.tsx b/plugins/catalog/src/components/CatalogKindHeader/CatalogKindHeader.tsx index bb9e98d9c3..2cb8709c34 100644 --- a/plugins/catalog/src/components/CatalogKindHeader/CatalogKindHeader.tsx +++ b/plugins/catalog/src/components/CatalogKindHeader/CatalogKindHeader.tsx @@ -59,7 +59,10 @@ export interface CatalogKindHeaderProps { initialFilter?: string; } -/** @public */ +/** + * @public + * @deprecated + */ export function CatalogKindHeader(props: CatalogKindHeaderProps) { const { initialFilter = 'component', allowedKinds } = props; const classes = useStyles(); diff --git a/plugins/catalog/src/components/CatalogPage/DefaultCatalogPage.tsx b/plugins/catalog/src/components/CatalogPage/DefaultCatalogPage.tsx index c5208c94f5..644453f5fb 100644 --- a/plugins/catalog/src/components/CatalogPage/DefaultCatalogPage.tsx +++ b/plugins/catalog/src/components/CatalogPage/DefaultCatalogPage.tsx @@ -39,7 +39,6 @@ import { import React, { ReactNode } from 'react'; import { createComponentRouteRef } from '../../routes'; import { CatalogTable, CatalogTableRow } from '../CatalogTable'; -import { CatalogKindHeader } from '../CatalogKindHeader'; import { useCatalogPluginOptions } from '../../options'; /** @@ -73,17 +72,15 @@ export function DefaultCatalogPage(props: DefaultCatalogPageProps) { return ( - - - } - > - - All your software catalog entities - + + + + All your software catalog entities + + @@ -103,8 +100,8 @@ export function DefaultCatalogPage(props: DefaultCatalogPageProps) { /> - - + + ); } From 2e6d0a9558bb54475468f32912c2d9e46b3d8bb3 Mon Sep 17 00:00:00 2001 From: Luca Huettner Date: Wed, 30 Nov 2022 16:17:38 +0100 Subject: [PATCH 2/6] chore: Update api report Signed-off-by: Luca Huettner --- plugins/catalog/api-report.md | 2 +- .../src/components/CatalogKindHeader/CatalogKindHeader.tsx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/catalog/api-report.md b/plugins/catalog/api-report.md index 3f72df00e2..74f64882a8 100644 --- a/plugins/catalog/api-report.md +++ b/plugins/catalog/api-report.md @@ -73,7 +73,7 @@ export const CatalogEntityPage: () => JSX.Element; // @public (undocumented) export const CatalogIndexPage: (props: DefaultCatalogPageProps) => JSX.Element; -// @public (undocumented) +// @public @deprecated (undocumented) export function CatalogKindHeader(props: CatalogKindHeaderProps): JSX.Element; // @public diff --git a/plugins/catalog/src/components/CatalogKindHeader/CatalogKindHeader.tsx b/plugins/catalog/src/components/CatalogKindHeader/CatalogKindHeader.tsx index 2cb8709c34..61a3c6fb4f 100644 --- a/plugins/catalog/src/components/CatalogKindHeader/CatalogKindHeader.tsx +++ b/plugins/catalog/src/components/CatalogKindHeader/CatalogKindHeader.tsx @@ -61,7 +61,7 @@ export interface CatalogKindHeaderProps { /** * @public - * @deprecated + * @deprecated Might be removed in a future release. */ export function CatalogKindHeader(props: CatalogKindHeaderProps) { const { initialFilter = 'component', allowedKinds } = props; From 7bd22049aae0d1ee5a7a16c16359befe6fbf0797 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luca=20H=C3=BCttner?= Date: Thu, 1 Dec 2022 15:23:04 +0100 Subject: [PATCH 3/6] Update plugins/catalog/src/components/CatalogKindHeader/CatalogKindHeader.tsx MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Johan Haals Signed-off-by: Luca Hüttner --- .../src/components/CatalogKindHeader/CatalogKindHeader.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/catalog/src/components/CatalogKindHeader/CatalogKindHeader.tsx b/plugins/catalog/src/components/CatalogKindHeader/CatalogKindHeader.tsx index 61a3c6fb4f..2f7cb6dfd9 100644 --- a/plugins/catalog/src/components/CatalogKindHeader/CatalogKindHeader.tsx +++ b/plugins/catalog/src/components/CatalogKindHeader/CatalogKindHeader.tsx @@ -61,7 +61,7 @@ export interface CatalogKindHeaderProps { /** * @public - * @deprecated Might be removed in a future release. +* @deprecated This component has been deprecated in favour of the EntityKindPicker in the list of filters. If you wish to keep this component long term make sure to raise an issue at github.com/backstage/backstage */ export function CatalogKindHeader(props: CatalogKindHeaderProps) { const { initialFilter = 'component', allowedKinds } = props; From a9a86a897226ee28997abd76de5e98747c246ac3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luca=20H=C3=BCttner?= Date: Thu, 1 Dec 2022 15:23:17 +0100 Subject: [PATCH 4/6] Update .changeset/modern-camels-cheat.md MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Johan Haals Signed-off-by: Luca Hüttner --- .changeset/modern-camels-cheat.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.changeset/modern-camels-cheat.md b/.changeset/modern-camels-cheat.md index 69c680b989..9575a8f9a8 100644 --- a/.changeset/modern-camels-cheat.md +++ b/.changeset/modern-camels-cheat.md @@ -2,4 +2,4 @@ '@backstage/plugin-catalog': patch --- -Remove `CatalogKindHeader` from `DefaultCatalogPage`. Deprecate `CatalogKindHeader`. +Removed `CatalogKindHeader` from `DefaultCatalogPage`. Deprecated `CatalogKindHeader` in favour of `EntityKindPicker`. From fabe95dcdf5ccec049d19c06fa3345bc93eb010a Mon Sep 17 00:00:00 2001 From: Luca Huettner Date: Thu, 1 Dec 2022 15:38:19 +0100 Subject: [PATCH 5/6] style: Fix formatting Signed-off-by: Luca Huettner --- .../src/components/CatalogKindHeader/CatalogKindHeader.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/catalog/src/components/CatalogKindHeader/CatalogKindHeader.tsx b/plugins/catalog/src/components/CatalogKindHeader/CatalogKindHeader.tsx index 2f7cb6dfd9..67631a3b98 100644 --- a/plugins/catalog/src/components/CatalogKindHeader/CatalogKindHeader.tsx +++ b/plugins/catalog/src/components/CatalogKindHeader/CatalogKindHeader.tsx @@ -61,7 +61,7 @@ export interface CatalogKindHeaderProps { /** * @public -* @deprecated This component has been deprecated in favour of the EntityKindPicker in the list of filters. If you wish to keep this component long term make sure to raise an issue at github.com/backstage/backstage + * @deprecated This component has been deprecated in favour of the EntityKindPicker in the list of filters. If you wish to keep this component long term make sure to raise an issue at github.com/backstage/backstage */ export function CatalogKindHeader(props: CatalogKindHeaderProps) { const { initialFilter = 'component', allowedKinds } = props; From 68a2d370d1a0036d213cdc4e8a0084b54546edef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luca=20H=C3=BCttner?= Date: Thu, 1 Dec 2022 16:32:12 +0100 Subject: [PATCH 6/6] Update .changeset/modern-camels-cheat.md MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Johan Haals Signed-off-by: Luca Hüttner --- .changeset/modern-camels-cheat.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.changeset/modern-camels-cheat.md b/.changeset/modern-camels-cheat.md index 9575a8f9a8..c0a80934d5 100644 --- a/.changeset/modern-camels-cheat.md +++ b/.changeset/modern-camels-cheat.md @@ -1,5 +1,5 @@ --- -'@backstage/plugin-catalog': patch +'@backstage/plugin-catalog': minor --- Removed `CatalogKindHeader` from `DefaultCatalogPage`. Deprecated `CatalogKindHeader` in favour of `EntityKindPicker`.