File size: 554 Bytes
f5071ca
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
import React from 'react';
import { MenuItem, useColorModeValue } from '@chakra-ui/react';

const CustomMenuItem = ({ children, onClick, py }) => {
   return (
      <MenuItem
         py={py || '.5rem'}
         pos='relative'
         borderRadius='5px'
         _hover={{
            bg: useColorModeValue('light.secondary', 'dark.secondary'),
            color: useColorModeValue('light.headingHover', 'dark.headingHover'),
         }}
         onClick={onClick}
      >
         {children}
      </MenuItem>
   );
};

export default CustomMenuItem;