Skip to main content

Menu Props with types

PropsTypeDescriptionDefault
triggerPopouthover | clickIf click, submenu popper will open/close when clicking on MenuItemhover
browserScrollbooleanDisplay Browser scroll or Perfect Scrollbarfalse
transitionDurationnumberTransition duration (in ms) for the submenu300
menuItemStylesMenuItemStylesRender method for style customization on MenuItem and SubMenu components-
renderExpandIcon(params: { level: number; disabled: boolean; active: boolean; open: boolean; }) => ReactElementRender method for customizing submenu expand icon-
renderExpandedMenuItemIconRenderExpandedMenuItemIconRender method for customizing MenuItem & SubMenu icons-
textTruncatebooleanIf true, text will truncate in all the MenuItems and SubMenustrue
popoutMenuOffset{mainAxis?: number | ((params: { level?: number }) => number) alignmentAxis?: number | ((params: { level?: number }) => number) }Popout menu offset-
verticalMenuProps{verticalMenuProps?: Pick< VerticalMenuProps, | 'transitionDuration' | 'menuSectionStyles' | 'menuItemStyles' | 'subMenuOpenBehavior' | 'renderExpandIcon' | 'renderExpandedMenuItemIcon' | 'textTruncate' | 'rootStyles'>}Props to be passed to the VerticalMenu component when the menu is rendered vertically-
rootStylesCSSObjectSet custom styling for the menu-