Oihana Next UI - 0.1.11

Application logo

List Component

Basic List with Avatars

  • Most played songs this week
  • Dio Lupa
    Dio Lupa
    Remaining Reason
  • Ellie Beilish
    Ellie Beilish
    Bears of a fever
  • Sabrino Gardener
    Sabrino Gardener
    Cappuccino
<List className="bg-base-100 rounded-box shadow-md">
    <ListRow
        avatar={ <Avatar>...</Avatar> }
        title="Song Title"
        subtitle="Artist Name"
        actions={ [<Button />, <Button />] }
    />
</List>

Selectable List with Checkboxes

0 selected
  • Select songs to add to playlist
  • Dio Lupa
    Remaining Reason
  • Ellie Beilish
    Bears of a fever
  • Sabrino Gardener
    Cappuccino
<ListRow
    selectable
    selected={ isSelected }
    onSelect={ (checked) => setSelected(checked) }
    avatar={ <Avatar>...</Avatar> }
    title="Item title"
/>

List with Pagination

  • Displaying 1 to 5 of 25 items
  • Item 1
    Item 1
    Artist for item 1
  • Item 2
    Item 2
    Artist for item 2
  • Item 3
    Item 3
    Artist for item 3
  • Item 4
    Item 4
    Artist for item 4
  • Item 5
    Item 5
    Artist for item 5
// Example layout structure
<div className="flex flex-col gap-4">
    <List>...</List>
    <div className="flex justify-center">
        <Pagination ... />
    </div>
</div>

List with Leading Numbers (Third Column Grows)

  • Top tracks of the month
  • 01
    Dio Lupa
    Dio Lupa
    Remaining Reason
  • 02
    Ellie Beilish
    Ellie Beilish
    Bears of a fever
  • 03
    Sabrino Gardener
    Sabrino Gardener
    Cappuccino
<ListRow
    leading={ <div className="text-4xl">01</div> }
    avatar={ <Avatar>...</Avatar> }
    grow={ <CustomContent /> }
    growColumn={ 3 }
/>

List with Wrapped Content

  • Songs with descriptions
  • Dio Lupa
    Dio Lupa
    Remaining Reason

    "Remaining Reason" became an instant hit, praised for its haunting sound and emotional depth.

  • Ellie Beilish
    Ellie Beilish
    Bears of a fever

    "Bears of a Fever" captivated audiences with its intense energy and mysterious lyrics.

  • Sabrino Gardener
    Sabrino Gardener
    Cappuccino

    "Cappuccino" quickly gained attention for its smooth melody and relatable themes.

<ListRow
    avatar={ <Avatar>...</Avatar> }
    title="Title"
    subtitle="Subtitle"
    wrap={ <p>Long description that wraps...</p> }
    actions={ <Button /> }
/>

Clickable List Rows

  • Click on a row
  • Dio Lupa
    Dio Lupa
    Remaining Reason
  • Ellie Beilish
    Ellie Beilish
    Bears of a fever
  • Sabrino Gardener
    Sabrino Gardener
    Cappuccino
<ListRow
    clickable
    onClick={ () => handleClick() }
    title="Clickable item"
/>

Users List with Status and Multiple Actions

  • Team members
  • Jane Cooper
    Jane Cooper
    jane@example.com
  • Wade Warren
    Wade Warren
    wade@example.com
  • Esther Howard
    Esther Howard
    esther@example.com
<ListRow
    avatar={ <Avatar indicator="online">...</Avatar> }
    grow={ <div><h3>Name</h3><p>Email</p></div> }
    content={ <div><Badge>Role</Badge></div> }
    actions={ [<Button />, <Button />, <Button />] }
/>

Custom Content Layout

  • Featured products
  • 4.8
    Premium Wooden Table
    Handcrafted oak wood
    NewIn Stock
  • 4.6
    Ergonomic Chair
    Comfortable design
    Sale
<ListRow
    leading={ <Rating /> }
    grow={ <ProductInfo /> }
    content={ <Price /> }
    actions={ <Button>Add to Cart</Button> }
/>

Props Reference

PropTypeDescription
avatarReactNodeAvatar element (replaced by checkbox when selectable)
selectablebooleanShow checkbox instead of avatar
selectedbooleanCheckbox selected state
onSelectfunctionSelection change handler: (checked) => void
titlestringMain title text
subtitlestringSubtitle text (small, uppercase)
leadingReactNodeElement before avatar/checkbox
growReactNodeCustom content for grow column
growColumnnumberWhich column grows (default: 2)
wrapReactNodeContent that wraps to next row
actionsReactNode | ArrayAction buttons on the right
clickablebooleanAdd hover/cursor styles
onClickfunctionRow click handler