Skip to content

MenuGroupProps

Property Type Description Inherited from
as? ElementType Custom element to render the MenuItem as. Overrides the itemType prop. Should only be used when the itemType prop is not sufficient, for example when using a custom Routing component and rendering the MenuItem as a Link-component from a routing library. MenuItemProps.as
children? ReactNode - MenuItemProps.children
command? string Right-aligned label text content, useful for displaying hotkeys MenuItemProps.command
href? string Link destination to use with itemType ‘link’. MenuItemProps.href
isDisabled? boolean If true, the MenuItem will be disabled. MenuItemProps.isDisabled
itemType? MenuItemType Type based on what element is used within the MenuItem. Internally translates the type into what html element to render the MenuItem as. Defaults to a button element. MenuItemProps.itemType
leftIcon? CasperIconComponent Icon to render to the left of the MenuItem contents. MenuItemProps.leftIcon
onClick? MouseEventHandler<HTMLDivElement> - MenuItemProps.onClick
rightElement? ReactNode Element to render to the right of the SubMenu Item contents. -
rightIcon? CasperIconComponent Icon to render to the right of the MenuItem contents. MenuItemProps.rightIcon
text string Text to render within the SubMenu Item. -
to? string For usage with routing libraries. If the MenuItem is a custom Link component, this prop can be used to specify the route. MenuItemProps.to
value string The unique value of the menu item option. MenuItemProps.value