Item

A list row with title, description and leading/trailing slots.

Import

import { Item } from "@tarve/core";

Usage

Item.tsx
import { Avatar, Badge, Item } from "@tarve/core";

<Item
  title="Ada Lovelace"
  description="ada@example.com"
  leading={<Avatar fallback="AL" size={32} />}
  trailing={<Badge variant="secondary">Owner</Badge>}
  onClick={() => console.log("open profile")}
/>

Props

PropTypeDefault
title required string—
description string—
disabled boolean—
leading Child—
onClick () => void—
selected boolean—
trailing Child—

Common props

Shared by every component. See descriptions →

childrenhighlightidkeymotionFromonHighlightonPasteonTransitionEndrovingGroupstyle