diff --git a/src/theme/NavbarItem/DocsVersionDropdownNavbarItem.tsx b/src/theme/NavbarItem/DocsVersionDropdownNavbarItem.tsx new file mode 100644 index 00000000..1d650a37 --- /dev/null +++ b/src/theme/NavbarItem/DocsVersionDropdownNavbarItem.tsx @@ -0,0 +1,14 @@ +import React from 'react'; +import DocsVersionDropdownNavbarItem from '@theme-original/NavbarItem/DocsVersionDropdownNavbarItem'; +import { useLocation } from '@docusaurus/router'; +import type { Props } from '@theme/NavbarItem/DocsVersionDropdownNavbarItem'; + +function isNonVersionedPathname(pathname: string) { + return pathname.startsWith('/fabric') || pathname.startsWith('/release-notes'); +} + +export default function DocsVersionDropdownNavbarItemWrapper(props: Props) { + const location = useLocation(); + + return isNonVersionedPathname(location.pathname) ? null : ; +}