diff --git a/public/app/core/components/NavBar/Next/NavBarMenu.tsx b/public/app/core/components/NavBar/Next/NavBarMenu.tsx index 750f86dd091..3ea31a4e153 100644 --- a/public/app/core/components/NavBar/Next/NavBarMenu.tsx +++ b/public/app/core/components/NavBar/Next/NavBarMenu.tsx @@ -11,6 +11,7 @@ import { reportInteraction } from '@grafana/runtime'; import { CollapsableSection, CustomScrollbar, Icon, IconButton, IconName, useStyles2, useTheme2 } from '@grafana/ui'; import { Branding } from '../../Branding/Branding'; +import { NavFeatureHighlight } from '../NavFeatureHighlight'; import { isMatchOrChildMatch } from '../utils'; import { NavBarItemWithoutMenu } from './NavBarItemWithoutMenu'; @@ -255,6 +256,7 @@ function NavItem({ ); } else { + const FeatureHighlightWrapper = link.highlightText ? NavFeatureHighlight : React.Fragment; return (
  • -
    {getLinkIcon(link)}
    +
    + {getLinkIcon(link)} +
    {link.text}
    @@ -339,6 +343,7 @@ function CollapsibleNavItem({ }) { const styles = useStyles2(getCollapsibleStyles); const [sectionExpanded, setSectionExpanded] = useLocalStorage(`grafana.navigation.expanded[${link.text}]`, false); + const FeatureHighlightWrapper = link.highlightText ? NavFeatureHighlight : React.Fragment; return (
  • @@ -354,7 +359,7 @@ function CollapsibleNavItem({ className={styles.collapsibleMenuItem} elClassName={styles.collapsibleIcon} > - {getLinkIcon(link)} + {getLinkIcon(link)}
    ; } else if (link.icon) { return ; - } else if (link.img) { - return {`${link.text}; } else { - return null; + return {`${link.text}; } }