Skip to content

MenuGroup

const MenuGroup: ({
text,
children,
onClick,
as,
isDisabled,
command,
itemType,
leftIcon,
rightIcon,
rightElement,
...props
}: MenuGroupProps) => React.JSX.Element;

A variant of MenuItem that renders children as nested list of maximum three levels. The SubMenu is collapsible and can be toggled by clicking the SubMenu IconButton.

Parameter Type
{ text, children, onClick, as, isDisabled, command, itemType, leftIcon, rightIcon, rightElement, ...props } MenuGroupProps

React.JSX.Element

Differs from MenuItem in that it renders text via the text prop, and can render an element to the right of text via the rightElement prop.