Skip to content
SevenOne

Search documentation

Search pages and components

Item

A row with media, a title, a description and actions. 16px text and 16px padding; the icon box is 32px and images are 40px.

Installation

npx shadcn@latest add @sevenone/item

Usage

import {
  Item,
  ItemActions,
  ItemContent,
  ItemDescription,
  ItemGroup,
  ItemMedia,
  ItemSeparator,
  ItemTitle,
} from "@/components/ui/item"

Examples

Default

Basic Item

A simple item with title and description.

Your profile has been verified.
<Item variant="outline">
  <ItemContent>
    <ItemTitle>Basic Item</ItemTitle>
    <ItemDescription>A simple item with title and description.</ItemDescription>
  </ItemContent>
  <ItemActions>
    <Button variant="outline" size="sm">Action</Button>
  </ItemActions>
</Item>
<Item variant="outline" size="sm" asChild>
  <a href="/profile">
    <ItemMedia>
      <BadgeCheck aria-hidden="true" />
    </ItemMedia>
    <ItemContent>
      <ItemTitle>Your profile has been verified.</ItemTitle>
    </ItemContent>
    <ItemActions>
      <ChevronRight aria-hidden="true" />
    </ItemActions>
  </a>
</Item>

Group

Inside an ItemGroup, items are a list, so screen readers say how many there are.

Documentation

How to install and theme SevenOne.

Components

Every component with examples and code.

Accessibility

What each component does for 7:1 and 44px.

<ItemGroup className="rounded-md border">
  <Item>
    <ItemMedia variant="icon">
      <BookOpen aria-hidden="true" />
    </ItemMedia>
    <ItemContent>
      <ItemTitle>Documentation</ItemTitle>
      <ItemDescription>How to install and theme SevenOne.</ItemDescription>
    </ItemContent>
  </Item>
  <ItemSeparator />
  <Item>…</Item>
</ItemGroup>

Accessibility

  • Inside an ItemGroup each item is a list item; a link item gets a list item around it, so it stays a link.
  • Use asChild with a link or button when the whole row is clickable; it gets the 2px focus ring.
  • Icons are decoration, so mark them aria-hidden; give images a useful alt text.
  • Buttons in ItemActions are 44px tall.