List

List supports two kinds of modes (default and card).

<List>
  <List.Item>content</List.Item>
</List>

Example

Basic usage of List component.

API

List

PropertiesDescriptionTypeDefault
modeSupport two modes: default and card.'default' | 'card''default'

List.Item

PropertiesDescriptionTypeDefault
titleThe title area in the upper middle of the list item.ReactNode-
childrenThe main content area in the middle of the list item.ReactNode-
descriptionThe description area in the lower middle of the list item.ReactNode-
prefixThe left area of the list item.ReactNode-
extraThe right area of the list item.ReactNode-
clickableWhether the list item could be clickable.booleanDefaults to true when the onClick prop is present, otherwise defaults to false
arrowWhether to show the arrow icon on the right side, also supports passing ReactNode to customize the icon.boolean | ReactNodesame as clickable
disabledWhether the list item could be disabled.booleanfalse
onClickThe click event of the list item. When the onClick property is passed on, the list item will display click effect.(e: React.MouseEvent) => void-