List
The List component is a continuous vertical index of text or images. The List component uses List Item or Nav-List Item components to create a list.
Style Attributes
Name | Type | Default | Description |
---|---|---|---|
dense | bool | false | If true, compact vertical padding is used for the list and list items. |
disablePadding | bool | false | If true, the vertical padding is removed from the list. |
Subcomponents
The List component has two possible subcomponents, the List Item and the Nav-List Item.
List Item
A text-based item for a list.
For further details, see the List Item component.
Properties
Name | Type | Default | Description |
---|---|---|---|
text | string | The text for the list item. | |
button | bool | false | If true, the list item is a button and enables the selected and disabled properties. |
selected | bool | false | If true, a selected style is applied to the list item. |
disabled | bool | false | If true, the list item is disabled. |
Nav-List Item
A navigational element within a list.
For further details, see the Nav-List Item component.
Properties
Name | Type | Default | Description |
---|---|---|---|
text | string | The text for the nav list item. | |
path | string | The navigational path for the nav list item. | |
exact | bool | false | If true, the active style will be applied if the location is matched exactly. |
disabled | bool | false | If true, the nav list item is disabled. |
The Add Left Component allows the placement of an icon, badge, chip or container to the left-hand side of a list item or nav-list item.
For more detail on the List component, see the MUI developer docs.