From 1fc0db2f64b8faf13590bc657d8cdb7ebecc6245 Mon Sep 17 00:00:00 2001 From: Remko Date: Wed, 25 Oct 2023 13:15:31 +0200 Subject: [PATCH] updated header to reslove maxDepth bug and updated header content --- .../templates/templateParts/header/HeaderContent.json | 10 +++++++++- .../templates/templateParts/header/HeaderTemplate.tsx | 2 +- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/pwa/src/templates/templateParts/header/HeaderContent.json b/pwa/src/templates/templateParts/header/HeaderContent.json index 458db3cb6..fb2c7985c 100644 --- a/pwa/src/templates/templateParts/header/HeaderContent.json +++ b/pwa/src/templates/templateParts/header/HeaderContent.json @@ -131,7 +131,15 @@ { "label": "Initiatives", "type": "internal", - "current": "pathname === \"/components\" && filters.developmentStatus === \"concept\"", + "current": { + "pathname": "/components", + "operator": "includes", + "filterCondition": { + "filter": "developmentStatus", + "value": "concept", + "isObject": true + } + }, "handleClick": { "link": "/components", "setFilter": { diff --git a/pwa/src/templates/templateParts/header/HeaderTemplate.tsx b/pwa/src/templates/templateParts/header/HeaderTemplate.tsx index 639ac5570..7a12909bf 100644 --- a/pwa/src/templates/templateParts/header/HeaderTemplate.tsx +++ b/pwa/src/templates/templateParts/header/HeaderTemplate.tsx @@ -171,7 +171,7 @@ export const HeaderTemplate: React.FC = ({ layoutClassName process.env.GATSBY_HEADER_SHOW_LOGIN === "true" ? setTopNavItems([...itemsArray, ...secondaryTopNavItemsMobile]) : setTopNavItems(itemsArray); - }, [screenSize, pathname, crumbs, getHeaderContent.isSuccess]); + }, [screenSize, pathname, crumbs, filters]); return (