MenuItem
The MenuItem component based on the
Button.
Props
Props of the
MenuItem component are also available.
Name | Type | Default | Description |
---|
children or label | node | | The content of the component. |
Component | element type | 'span' or 'a' | The component used for the root node. Either a string to use a HTML element or a component. |
size | string - none, small, default, large | default | Set padding from presets were specified in the theme. The component passes this property to the Typography component as a variant prefixed with "label-". |
inset | bool | false | If true, the children are indented. |
The ref
is forwarded to the root Button element.
Examples
MenuItems with large size and inheriting color from paper
MenuItems with default size and with secondary color on 'paper1' colored Paper
MenuItems with small size and inheriting 'paper2' color from paper
MenuItems with custom Typography variant and 'featured' colors