From dfb5282eb528ebeb91334d85f14108335fdf7178 Mon Sep 17 00:00:00 2001 From: Pascal Fischer Date: Tue, 23 May 2023 21:01:55 +0200 Subject: [PATCH] fix dropdowns path searcha nd replace --- src/components/NavigationAPI.jsx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/components/NavigationAPI.jsx b/src/components/NavigationAPI.jsx index 38095121..68727ca4 100644 --- a/src/components/NavigationAPI.jsx +++ b/src/components/NavigationAPI.jsx @@ -138,7 +138,7 @@ function NavigationGroup({ group, className, tableOfContents }) { let router = useRouter() let isActiveGroup = - group.links.findIndex((link) => link.href === router.pathname) !== -1 + group.links.findIndex((link) => link.href === router.pathname.replace("ipa", "api")) !== -1 return (
  • @@ -151,7 +151,7 @@ function NavigationGroup({ group, className, tableOfContents }) {
    {isActiveGroup && ( - + )} {isActiveGroup && ( - + )}
      {group.links.map((link) => ( - + {link.title} - {link.href === router.pathname && ( + {link.href === router.pathname.replace("ipa", "api") && (