From b545e516156a9f80006a4a38108a9eebe0f121ed Mon Sep 17 00:00:00 2001 From: Emma Indal Date: Thu, 20 Aug 2020 15:02:53 +0200 Subject: [PATCH] fix(header tabs): use filteredheadertabs instead of tabs --- plugins/catalog/src/components/EntityPage/EntityPage.tsx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/plugins/catalog/src/components/EntityPage/EntityPage.tsx b/plugins/catalog/src/components/EntityPage/EntityPage.tsx index a36ac32a07..adbc758067 100644 --- a/plugins/catalog/src/components/EntityPage/EntityPage.tsx +++ b/plugins/catalog/src/components/EntityPage/EntityPage.tsx @@ -206,10 +206,12 @@ export const EntityPage: FC<{}> = () => { tabs={filteredHeaderTabs} onChange={idx => { navigate( - `/catalog/${kind}/${optionalNamespaceAndName}/${tabs[idx].id}`, + `/catalog/${kind}/${optionalNamespaceAndName}/${filteredHeaderTabs[idx].id}`, ); }} - selectedIndex={tabs.findIndex(tab => tab.id === selectedTabId)} + selectedIndex={filteredHeaderTabs.findIndex( + tab => tab.id === selectedTabId, + )} /> {selectedTab && selectedTab.content