diff --git a/components/NavigationMenu/NavigationMenu.stories.tsx b/components/NavigationMenu/NavigationMenu.stories.tsx index eec5872c..7ba80c9a 100644 --- a/components/NavigationMenu/NavigationMenu.stories.tsx +++ b/components/NavigationMenu/NavigationMenu.stories.tsx @@ -4,9 +4,8 @@ import React from 'react'; import { modifyVariantsForStory } from '../../utils/modifyVariantsForStory'; import { Container } from '../Container'; -import { Flex } from '../Flex'; import { Link } from '../Link'; -import { NavigationTreeContainer, NavigationTreeItem } from '../NavigationTree'; +import { NavigationItem } from '../Navigation'; import { Text } from '../Text'; import { NavigationMenu, @@ -17,7 +16,6 @@ import { NavigationMenuProps, NavigationMenuTrigger, NavigationMenuVariants, - NavigationMenuViewport, } from './NavigationMenu'; const BaseNavigationMenu = (props: NavigationMenuProps): JSX.Element => ( @@ -39,34 +37,32 @@ const Template: StoryFn = (args) => ( - Menu links + Links - - - - A link - - - Another link - - + + + A link + + + Another link + - Navigation tree items + Navigation items - - - } /> - } /> - + + + }>Profile + + + }>Settings + - - ); diff --git a/components/NavigationMenu/NavigationMenu.tsx b/components/NavigationMenu/NavigationMenu.tsx index 5a332ffa..b4932ed4 100644 --- a/components/NavigationMenu/NavigationMenu.tsx +++ b/components/NavigationMenu/NavigationMenu.tsx @@ -13,6 +13,7 @@ const StyledRoot = styled(NavigationMenuPrimitive.Root, { p: 0, listStyleType: 'none', li: { + position: 'relative', display: 'inline', }, }, @@ -39,6 +40,9 @@ export const NavigationMenu = React.forwardRef< // #region Content const StyledContent = styled(NavigationMenuPrimitive.Content, panelStyles, { + position: 'absolute', + left: 0, + p: '$2', color: '$hiContrast', '&:focus': { outline: 'none',