Commit 7a2d5858 authored by isstuev's avatar isstuev

fix menu again

parent 3b8c6a27
...@@ -38,12 +38,19 @@ const NavigationMobile = () => { ...@@ -38,12 +38,19 @@ const NavigationMobile = () => {
const openedItem = mainNavItems[openedGroupIndex]; const openedItem = mainNavItems[openedGroupIndex];
return ( return (
<> <Flex position="relative" flexDirection="column" flexGrow={ 1 }>
<Box position="relative">
<Box <Box
as={ motion.nav } display="flex"
mt={ 6 } flexDirection="column"
flexGrow={ 1 }
as={ motion.div }
style={{ x: mainX }} style={{ x: mainX }}
maxHeight={ openedGroupIndex > -1 ? '100vh' : 'unset' }
overflowY={ openedGroupIndex > -1 ? 'hidden' : 'unset' }
>
<Box
as="nav"
mt={ 6 }
> >
<VStack <VStack
w="100%" w="100%"
...@@ -62,18 +69,19 @@ const NavigationMobile = () => { ...@@ -62,18 +69,19 @@ const NavigationMobile = () => {
</Box> </Box>
{ isAuth && ( { isAuth && (
<Box <Box
as={ motion.nav } as="nav"
mt={ 6 } mt={ 6 }
pt={ 6 } pt={ 6 }
borderTopWidth="1px" borderTopWidth="1px"
borderColor="divider" borderColor="divider"
style={{ x: mainX }}
> >
<VStack as="ul" spacing="1" alignItems="flex-start"> <VStack as="ul" spacing="1" alignItems="flex-start">
{ accountNavItems.map((item) => <NavLink key={ item.text } item={ item }/>) } { accountNavItems.map((item) => <NavLink key={ item.text } item={ item }/>) }
</VStack> </VStack>
</Box> </Box>
) } ) }
<NavFooter hasAccount={ hasAccount }/>
</Box>
{ openedGroupIndex >= 0 && ( { openedGroupIndex >= 0 && (
<Box <Box
as={ motion.nav } as={ motion.nav }
...@@ -113,9 +121,7 @@ const NavigationMobile = () => { ...@@ -113,9 +121,7 @@ const NavigationMobile = () => {
</Box> </Box>
</Box> </Box>
) } ) }
</Box> </Flex>
<NavFooter hasAccount={ hasAccount }/>
</>
); );
}; };
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment