List API
View componentThe full prop reference for the List component. A vertical list of items and actions.
Import
tsx
import { List } from '@structyl/styled';Props
List.Root
List container.
| Prop | Type | Default |
|---|---|---|
| dense# | booleanCompact item density. | false |
| disablePadding# | booleanRemove root padding. | false |
| className# | stringAdditional Tailwind classes merged with the component defaults. | — |
List.Item
List item.
| Prop | Type | Default |
|---|---|---|
| disablePadding# | booleanRemove item padding. | false |
| divider# | booleanShow bottom divider. | false |
| className# | stringAdditional Tailwind classes merged with the component defaults. | — |
List.ItemButton
Clickable list row.
| Prop | Type | Default |
|---|---|---|
| selected# | booleanSelected styling. | false |
| dense# | booleanCompact row. | false |
| disabled# | booleanDisable row. | false |
| alignItems# | 'center' | 'flex-start'Row alignment. | 'center' |
| className# | stringAdditional Tailwind classes merged with the component defaults. | — |
List.ItemText
Primary and secondary text.
| Prop | Type | Default |
|---|---|---|
| primary | secondary# | React.ReactNodeText slots. | — |
| inset# | booleanAlign text with icon rows. | false |
| className# | stringAdditional Tailwind classes merged with the component defaults. | — |
List.ItemIcon / ItemAvatar / ItemSecondaryAction / Subheader
Additional list slots.
| Prop | Type | Default |
|---|---|---|
| className# | stringAdditional Tailwind classes merged with the component defaults. | — |
Source code
If you didn't find what you need here, read the component implementation .