import React, { ReactNode } from 'react'; import { css, cx } from '@emotion/css'; import { GrafanaTheme2 } from '@grafana/data'; import { useTheme2 } from '@grafana/ui'; import { config } from '@grafana/runtime'; export interface Props { children: ReactNode; className?: string; } export function NavBarSection({ children, className }: Props) { const newNavigationEnabled = Boolean(config.featureToggles.newNavigation); const theme = useTheme2(); const styles = getStyles(theme, newNavigationEnabled); return (