@brighthr/component-contextmenu
v3.2.1
Published
To install, type the following into the command line at the root of your project:
Readme
ContextMenu
To install, type the following into the command line at the root of your project:
npm i @brighthr/component-contextmenuTo implement the Checkbox component into your project you’ll need to add the import:
import {
ContextMenuListItem,
ContextMenu,
} from '@brighthr/component-contextmenu';After adding import into your project you can use it simply like:
<ContextMenu />Props
| Name | Type | Default | Description |
|---------------------|-------------------------------|---------|----------------------------------------------------------|
| children | React.ReactNode | | The content of the ContextMenu. |
| contextName | string | | Sets the ariaLabel value. |
| customTriggerLayout | React.ReactNode | | Sets a custom element to open the menu, e.g a chevron. |
| disabled | boolean | false | If true, disables the ContextMenu with a gray overlay. |
| menuPosition | 'left' 'right' 'center' | | Sets the side to which the menu will open. |
| onOpen | () => void | | Function for handling onOpen event. |
| text | string | | Sets some text to describe what is in the menu. |
