Skip to content
GitHub

Item

A versatile component for displaying content with media, title, description, and actions.

  • New comment

    Someone replied to your post.

  • New message

    You have a new direct message.

import { Button } from "@/components/ui/pxl/button";
import {
Item,
ItemActions,
ItemContent,
ItemDescription,
ItemGroup,
ItemMedia,
ItemSeparator,
ItemTitle,
} from "@/components/ui/pxl/item";
export default function ItemDemo() {
return (
<ItemGroup className="w-full max-w-md">
<Item variant="outline">
<ItemMedia variant="icon">
<svg
xmlns="http://www.w3.org/2000/svg"
fill="currentColor"
viewBox="0 0 24 24"
>
<path d="M9 2h6v2H9zM7 4h2v2H7zm8 0h2v2h-2zM5 6h2v7H5zm12 0h2v7h-2zM3 13h2v4H3zm16 0h2v4h-2z"></path>
<path d="M3 15h18v2H3zm5 3h2v2H8zm6 0h2v2h-2zm-4 2h4v2h-4z"></path>
</svg>
</ItemMedia>
<ItemContent>
<ItemTitle>New comment</ItemTitle>
<ItemDescription>Someone replied to your post.</ItemDescription>
</ItemContent>
<ItemActions>
<Button size="sm" variant="outline">
View
</Button>
</ItemActions>
</Item>
<ItemSeparator />
<Item variant="outline">
<ItemMedia variant="icon">
<svg
xmlns="http://www.w3.org/2000/svg"
fill="currentColor"
viewBox="0 0 24 24"
>
<path d="M20 20H4v-2h16v2ZM4 18H2V6h2v12Zm18 0h-2V6h2v12Zm-8-4h-4v-2h4v2Zm-4-2H8v-2h2v2Zm6 0h-2v-2h2v2Zm-8-2H6V8h2v2Zm10 0h-2V8h2v2Zm2-4H4V4h16v2Z"></path>
</svg>
</ItemMedia>
<ItemContent>
<ItemTitle>New message</ItemTitle>
<ItemDescription>You have a new direct message.</ItemDescription>
</ItemContent>
<ItemActions>
<Button size="sm" variant="outline">
View
</Button>
</ItemActions>
</Item>
</ItemGroup>
);
}

The Item component is a straightforward flex container that can house nearly any type of content. Use it to display a title, description, and actions. Group it with the ItemGroup component to create a list of items.

pnpm dlx shadcn@latest add pxl-ui/registry/item
import {
Item,
ItemActions,
ItemContent,
ItemDescription,
ItemMedia,
ItemTitle,
} from "@/components/ui/pxl/item"
<Item>
<ItemMedia variant="icon">
<Icon />
</ItemMedia>
<ItemContent>
<ItemTitle>Title</ItemTitle>
<ItemDescription>Description</ItemDescription>
</ItemContent>
<ItemActions>
<Button>Action</Button>
</ItemActions>
</Item>

Use the following composition to build an Item:

ItemGroup
└── Item
├── ItemHeader
├── ItemMedia
├── ItemContent
│ ├── ItemTitle
│ └── ItemDescription
├── ItemActions
└── ItemFooter

Use the variant prop to change the visual style of the item.

  • Default Variant

    Transparent background with no border.

  • Outline Variant

    Outlined style with a visible border.

  • Muted Variant

    Muted background for secondary content.

  • Primary Variant

    Primary background for secondary content.

  • Success Variant

    Success background for secondary content.

  • Danger Variant

    Danger background for secondary content.

  • Warning Variant

    Warning background for secondary content.

  • Info Variant

    Info background for secondary content.

  • import {
    Item,
    ItemContent,
    ItemDescription,
    ItemMedia,
    ItemTitle,
    } from "@/components/ui/pxl/item";
    export default function ItemVariantExample() {
    return (
    <div className="flex w-full max-w-md flex-col gap-6">
    <Item>
    <ItemMedia variant="icon">
    <svg
    xmlns="http://www.w3.org/2000/svg"
    fill="currentColor"
    viewBox="0 0 24 24"
    >
    <path d="M20 22H4v-2h16v2ZM4 14h4v2H4v4H2V4h2v10Zm18 6h-2v-4h-4v-2h4V4h2v16Zm-6-2H8v-2h8v2Zm4-14H4V2h16v2Z"></path>
    </svg>
    </ItemMedia>
    <ItemContent>
    <ItemTitle>Default Variant</ItemTitle>
    <ItemDescription>
    Transparent background with no border.
    </ItemDescription>
    </ItemContent>
    </Item>
    <Item variant="outline">
    <ItemMedia variant="icon">
    <svg
    xmlns="http://www.w3.org/2000/svg"
    fill="currentColor"
    viewBox="0 0 24 24"
    >
    <path d="M20 22H4v-2h16v2ZM4 14h4v2H4v4H2V4h2v10Zm18 6h-2v-4h-4v-2h4V4h2v16Zm-6-2H8v-2h8v2Zm4-14H4V2h16v2Z"></path>
    </svg>
    </ItemMedia>
    <ItemContent>
    <ItemTitle>Outline Variant</ItemTitle>
    <ItemDescription>
    Outlined style with a visible border.
    </ItemDescription>
    </ItemContent>
    </Item>
    <Item variant="muted">
    <ItemMedia variant="icon">
    <svg
    xmlns="http://www.w3.org/2000/svg"
    fill="currentColor"
    viewBox="0 0 24 24"
    >
    <path d="M20 22H4v-2h16v2ZM4 14h4v2H4v4H2V4h2v10Zm18 6h-2v-4h-4v-2h4V4h2v16Zm-6-2H8v-2h8v2Zm4-14H4V2h16v2Z"></path>
    </svg>
    </ItemMedia>
    <ItemContent>
    <ItemTitle>Muted Variant</ItemTitle>
    <ItemDescription>
    Muted background for secondary content.
    </ItemDescription>
    </ItemContent>
    </Item>
    <Item variant="primary">
    <ItemMedia variant="icon">
    <svg
    xmlns="http://www.w3.org/2000/svg"
    fill="currentColor"
    viewBox="0 0 24 24"
    >
    <path d="M20 22H4v-2h16v2ZM4 14h4v2H4v4H2V4h2v10Zm18 6h-2v-4h-4v-2h4V4h2v16Zm-6-2H8v-2h8v2Zm4-14H4V2h16v2Z"></path>
    </svg>
    </ItemMedia>
    <ItemContent>
    <ItemTitle>Primary Variant</ItemTitle>
    <ItemDescription>
    Primary background for secondary content.
    </ItemDescription>
    </ItemContent>
    </Item>
    <Item variant="success">
    <ItemMedia variant="icon">
    <svg
    xmlns="http://www.w3.org/2000/svg"
    fill="currentColor"
    viewBox="0 0 24 24"
    >
    <path d="M20 22H4v-2h16v2ZM4 14h4v2H4v4H2V4h2v10Zm18 6h-2v-4h-4v-2h4V4h2v16Zm-6-2H8v-2h8v2Zm4-14H4V2h16v2Z"></path>
    </svg>
    </ItemMedia>
    <ItemContent>
    <ItemTitle>Success Variant</ItemTitle>
    <ItemDescription>
    Success background for secondary content.
    </ItemDescription>
    </ItemContent>
    </Item>
    <Item variant="danger">
    <ItemMedia variant="icon">
    <svg
    xmlns="http://www.w3.org/2000/svg"
    fill="currentColor"
    viewBox="0 0 24 24"
    >
    <path d="M20 22H4v-2h16v2ZM4 14h4v2H4v4H2V4h2v10Zm18 6h-2v-4h-4v-2h4V4h2v16Zm-6-2H8v-2h8v2Zm4-14H4V2h16v2Z"></path>
    </svg>
    </ItemMedia>
    <ItemContent>
    <ItemTitle>Danger Variant</ItemTitle>
    <ItemDescription>
    Danger background for secondary content.
    </ItemDescription>
    </ItemContent>
    </Item>
    <Item variant="warning">
    <ItemMedia variant="icon">
    <svg
    xmlns="http://www.w3.org/2000/svg"
    fill="currentColor"
    viewBox="0 0 24 24"
    >
    <path d="M20 22H4v-2h16v2ZM4 14h4v2H4v4H2V4h2v10Zm18 6h-2v-4h-4v-2h4V4h2v16Zm-6-2H8v-2h8v2Zm4-14H4V2h16v2Z"></path>
    </svg>
    </ItemMedia>
    <ItemContent>
    <ItemTitle>Warning Variant</ItemTitle>
    <ItemDescription>
    Warning background for secondary content.
    </ItemDescription>
    </ItemContent>
    </Item>
    <Item variant="info">
    <ItemMedia variant="icon">
    <svg
    xmlns="http://www.w3.org/2000/svg"
    fill="currentColor"
    viewBox="0 0 24 24"
    >
    <path d="M20 22H4v-2h16v2ZM4 14h4v2H4v4H2V4h2v10Zm18 6h-2v-4h-4v-2h4V4h2v16Zm-6-2H8v-2h8v2Zm4-14H4V2h16v2Z"></path>
    </svg>
    </ItemMedia>
    <ItemContent>
    <ItemTitle>Info Variant</ItemTitle>
    <ItemDescription>
    Info background for secondary content.
    </ItemDescription>
    </ItemContent>
    </Item>
    </div>
    );
    }

    Use the size prop to change the size of the item. Available sizes are default, sm, and sm.

  • Default Size

    The standard size for most use cases.

  • Small Size

    A compact size for dense layouts.

  • Extra Small Size

    The most compact size available.

  • import {
    Item,
    ItemContent,
    ItemDescription,
    ItemMedia,
    ItemTitle,
    } from "@/components/ui/pxl/item";
    export default function ItemSizeExample() {
    return (
    <div className="flex w-full max-w-md flex-col gap-6">
    <Item variant="outline">
    <ItemMedia variant="icon">
    <svg
    xmlns="http://www.w3.org/2000/svg"
    fill="currentColor"
    viewBox="0 0 24 24"
    >
    <path d="M20 22H4v-2h16v2ZM4 14h4v2H4v4H2V4h2v10Zm18 6h-2v-4h-4v-2h4V4h2v16Zm-6-2H8v-2h8v2Zm4-14H4V2h16v2Z"></path>
    </svg>
    </ItemMedia>
    <ItemContent>
    <ItemTitle>Default Size</ItemTitle>
    <ItemDescription>
    The standard size for most use cases.
    </ItemDescription>
    </ItemContent>
    </Item>
    <Item variant="outline" size="sm">
    <ItemMedia variant="icon">
    <svg
    xmlns="http://www.w3.org/2000/svg"
    fill="currentColor"
    viewBox="0 0 24 24"
    >
    <path d="M20 22H4v-2h16v2ZM4 14h4v2H4v4H2V4h2v10Zm18 6h-2v-4h-4v-2h4V4h2v16Zm-6-2H8v-2h8v2Zm4-14H4V2h16v2Z"></path>
    </svg>
    </ItemMedia>
    <ItemContent>
    <ItemTitle>Small Size</ItemTitle>
    <ItemDescription>A compact size for dense layouts.</ItemDescription>
    </ItemContent>
    </Item>
    <Item variant="outline" size="xs">
    <ItemMedia variant="icon">
    <svg
    xmlns="http://www.w3.org/2000/svg"
    fill="currentColor"
    viewBox="0 0 24 24"
    >
    <path d="M20 22H4v-2h16v2ZM4 14h4v2H4v4H2V4h2v10Zm18 6h-2v-4h-4v-2h4V4h2v16Zm-6-2H8v-2h8v2Zm4-14H4V2h16v2Z"></path>
    </svg>
    </ItemMedia>
    <ItemContent>
    <ItemTitle>Extra Small Size</ItemTitle>
    <ItemDescription>The most compact size available.</ItemDescription>
    </ItemContent>
    </Item>
    </div>
    );
    }

    Use ItemMedia with variant="icon" to display an icon.

  • Security Alert

    New login detected from unknown device.

  • import { Button } from "@/components/ui/pxl/button";
    import {
    Item,
    ItemActions,
    ItemContent,
    ItemDescription,
    ItemMedia,
    ItemTitle,
    } from "@/components/ui/pxl/item";
    export default function ItemIconExample() {
    return (
    <div className="flex w-full max-w-lg flex-col gap-6">
    <Item variant="outline">
    <ItemMedia variant="icon">
    <svg
    xmlns="http://www.w3.org/2000/svg"
    fill="currentColor"
    viewBox="0 0 24 24"
    >
    <path d="M14 22h-4v-2h4v2Zm-4-2H8v-2h2v2Zm6 0h-2v-2h2v2Zm-8-2H6v-2h2v2Zm10 0h-2v-2h2v2ZM6 16H4v-2h2v2Zm7 0h-2v-2h2v2Zm7 0h-2v-2h2v2ZM4 14H2V4h2v10Zm18 0h-2V4h2v10Zm-9-2h-2V6h2v6Zm7-8H4V2h16v2Z"></path>
    </svg>
    </ItemMedia>
    <ItemContent>
    <ItemTitle>Security Alert</ItemTitle>
    <ItemDescription>
    New login detected from unknown device.
    </ItemDescription>
    </ItemContent>
    <ItemActions>
    <Button size="sm" variant="outline">
    Review
    </Button>
    </ItemActions>
    </Item>
    </div>
    );
    }

    You can use ItemMedia with variant="avatar" to display an avatar.

  • P
    Princess

    Last seen 5 months ago

  • W
    No Team Members

    Invite your team to collaborate on this project.

  • import {
    Avatar,
    AvatarFallback,
    AvatarImage,
    } from "@/components/ui/pxl/avatar";
    import { Button } from "@/components/ui/pxl/button";
    import {
    Item,
    ItemActions,
    ItemContent,
    ItemDescription,
    ItemMedia,
    ItemTitle,
    } from "@/components/ui/pxl/item";
    export default function ItemAvatarExample() {
    return (
    <div className="flex w-full max-w-lg flex-col gap-6">
    <Item variant="outline">
    <ItemMedia>
    <Avatar className="size-10">
    <AvatarImage className="bg-success" src="https://raw.githubusercontent.com/pxl-ui/registry/main/app/public/portraits/princess.png" />
    <AvatarFallback>P</AvatarFallback>
    </Avatar>
    </ItemMedia>
    <ItemContent>
    <ItemTitle>Princess</ItemTitle>
    <ItemDescription>Last seen 5 months ago</ItemDescription>
    </ItemContent>
    <ItemActions>
    <Button
    size="icon-sm"
    variant="outline"
    className="rounded-full"
    aria-label="Invite"
    >
    <svg
    xmlns="http://www.w3.org/2000/svg"
    fill="currentColor"
    viewBox="0 0 24 24"
    >
    <path d="M13 11h7v2h-7v7h-2v-7H4v-2h7V4h2v7Z" />
    </svg>
    </Button>
    </ItemActions>
    </Item>
    <Item variant="outline">
    <ItemMedia>
    <div className="flex -space-x-2 *:data-[slot=avatar]:ring-2 *:data-[slot=avatar]:ring-background *:data-[slot=avatar]:grayscale *:data-[slot=avatar]:group-hover/item:grayscale-0">
    <Avatar className="hidden sm:flex">
    <AvatarImage
    src="https://raw.githubusercontent.com/pxl-ui/registry/main/app/public/portraits/hero.png"
    alt="@hero"
    className="bg-primary"
    />
    <AvatarFallback>H</AvatarFallback>
    </Avatar>
    <Avatar className="hidden sm:flex">
    <AvatarImage
    src="https://raw.githubusercontent.com/pxl-ui/registry/main/app/public/portraits/princess.png"
    alt="@princess"
    className="bg-success"
    />
    <AvatarFallback>P</AvatarFallback>
    </Avatar>
    <Avatar>
    <AvatarImage
    src="https://raw.githubusercontent.com/pxl-ui/registry/main/app/public/portraits/wizard.png"
    alt="@wizard"
    className="bg-info"
    />
    <AvatarFallback>W</AvatarFallback>
    </Avatar>
    </div>
    </ItemMedia>
    <ItemContent>
    <ItemTitle>No Team Members</ItemTitle>
    <ItemDescription>
    Invite your team to collaborate on this project.
    </ItemDescription>
    </ItemContent>
    <ItemActions>
    <Button size="sm" variant="outline">
    Invite
    </Button>
    </ItemActions>
    </Item>
    </div>
    );
    }

    Use ItemMedia with variant="image" to display an image.

    /** biome-ignore-all lint/a11y/useValidAnchor: example */
    import {
    Item,
    ItemContent,
    ItemDescription,
    ItemGroup,
    ItemMedia,
    ItemTitle,
    } from "@/components/ui/pxl/item";
    export default function ItemImageExample() {
    return (
    <div className="flex w-full max-w-md flex-col gap-6">
    <ItemGroup className="gap-4">
    <Item variant="outline" role="listitem" render={
    <a href="#">
    <ItemMedia variant="image">
    <img
    src={`https://avatar.vercel.sh/midnight-city-lights`}
    alt="Midnight City Lights"
    width={32}
    height={32}
    className="object-cover grayscale group-hover/item:grayscale-0"
    />
    </ItemMedia>
    <ItemContent>
    <ItemTitle className="line-clamp-1">
    Midnight City Lights -{" "}
    <span className="text-muted-foreground">Electric Nights</span>
    </ItemTitle>
    <ItemDescription>Neon Dreams</ItemDescription>
    </ItemContent>
    <ItemContent className="flex-none text-center">
    <ItemDescription>3:45</ItemDescription>
    </ItemContent>
    </a>}
    />
    <Item variant="outline" role="listitem" render={
    <a href="#">
    <ItemMedia variant="image">
    <img
    src={`https://avatar.vercel.sh/coffee-shop-conversations`}
    alt="Coffee Shop Conversations"
    width={32}
    height={32}
    className="object-cover grayscale group-hover/item:grayscale-0"
    />
    </ItemMedia>
    <ItemContent>
    <ItemTitle className="line-clamp-1">
    Midnight City Lights -{" "}
    <span className="text-muted-foreground">Urban Stories</span>
    </ItemTitle>
    <ItemDescription>The Morning Brew</ItemDescription>
    </ItemContent>
    <ItemContent className="flex-none text-center">
    <ItemDescription>4:05</ItemDescription>
    </ItemContent>
    </a>}
    />
    <Item variant="outline" role="listitem" render={
    <a href="#">
    <ItemMedia variant="image">
    <img
    src={`https://avatar.vercel.sh/coffee-shop-conversations`}
    alt="Coffee Shop Conversations"
    width={32}
    height={32}
    className="object-cover grayscale group-hover/item:grayscale-0"
    />
    </ItemMedia>
    <ItemContent>
    <ItemTitle className="line-clamp-1">
    Digital Rain -{" "}
    <span className="text-muted-foreground">Binary Beats</span>
    </ItemTitle>
    <ItemDescription>Cyber Symphony</ItemDescription>
    </ItemContent>
    <ItemContent className="flex-none text-center">
    <ItemDescription>3:30</ItemDescription>
    </ItemContent>
    </a>}
    />
    </ItemGroup>
    </div>
    )
    }

    Use ItemGroup to group related items together.

    • H
      Hero

      hero@pxl-ui.com

    • P
      Princess

      princess@pxl-ui.com

    • W
      wizard

      wizard@pxl-ui.com

    import {
    Avatar,
    AvatarFallback,
    AvatarImage,
    } from "@/components/ui/pxl/avatar";
    import { Button } from "@/components/ui/pxl/button";
    import {
    Item,
    ItemActions,
    ItemContent,
    ItemDescription,
    ItemGroup,
    ItemMedia,
    ItemTitle,
    } from "@/components/ui/pxl/item";
    export default function ItemGroupExample() {
    return (
    <ItemGroup className="max-w-sm">
    <Item variant="outline">
    <ItemMedia>
    <Avatar>
    <AvatarImage
    src="https://raw.githubusercontent.com/pxl-ui/registry/main/app/public/portraits/hero.png"
    className="bg-primary grayscale group-hover/item:grayscale-0"
    />
    <AvatarFallback>H</AvatarFallback>
    </Avatar>
    </ItemMedia>
    <ItemContent className="gap-1">
    <ItemTitle>Hero</ItemTitle>
    <ItemDescription>hero@pxl-ui.com</ItemDescription>
    </ItemContent>
    <ItemActions>
    <Button variant="ghost" size="icon" className="rounded-full">
    <svg
    xmlns="http://www.w3.org/2000/svg"
    fill="currentColor"
    viewBox="0 0 24 24"
    >
    <path d="M13 11h7v2h-7v7h-2v-7H4v-2h7V4h2v7Z" />
    </svg>
    </Button>
    </ItemActions>
    </Item>
    <Item variant="outline">
    <ItemMedia>
    <Avatar>
    <AvatarImage
    src="https://raw.githubusercontent.com/pxl-ui/registry/main/app/public/portraits/princess.png"
    className="bg-success grayscale group-hover/item:grayscale-0"
    />
    <AvatarFallback>P</AvatarFallback>
    </Avatar>
    </ItemMedia>
    <ItemContent className="gap-1">
    <ItemTitle>Princess</ItemTitle>
    <ItemDescription>princess@pxl-ui.com</ItemDescription>
    </ItemContent>
    <ItemActions>
    <Button variant="ghost" size="icon" className="rounded-full">
    <svg
    xmlns="http://www.w3.org/2000/svg"
    fill="currentColor"
    viewBox="0 0 24 24"
    >
    <path d="M13 11h7v2h-7v7h-2v-7H4v-2h7V4h2v7Z" />
    </svg>
    </Button>
    </ItemActions>
    </Item>
    <Item variant="outline">
    <ItemMedia>
    <Avatar>
    <AvatarImage
    src="https://raw.githubusercontent.com/pxl-ui/registry/main/app/public/portraits/wizard.png"
    className="bg-info grayscale group-hover/item:grayscale-0"
    />
    <AvatarFallback>W</AvatarFallback>
    </Avatar>
    </ItemMedia>
    <ItemContent className="gap-1">
    <ItemTitle>wizard</ItemTitle>
    <ItemDescription>wizard@pxl-ui.com</ItemDescription>
    </ItemContent>
    <ItemActions>
    <Button variant="ghost" size="icon" className="rounded-full">
    <svg
    xmlns="http://www.w3.org/2000/svg"
    fill="currentColor"
    viewBox="0 0 24 24"
    >
    <path d="M13 11h7v2h-7v7h-2v-7H4v-2h7V4h2v7Z" />
    </svg>
    </Button>
    </ItemActions>
    </Item>
    </ItemGroup>
    );
    }

    Use ItemHeader to add a header above the item content.

    • v0-1.5-sm
      v0-1.5-sm

      Everyday tasks and UI generation.

    • v0-1.5-lg
      v0-1.5-lg

      Advanced thinking or reasoning.

    • v0-2.0-mini
      v0-2.0-mini

      Open Source model for everyone.

    import {
    Item,
    ItemContent,
    ItemDescription,
    ItemGroup,
    ItemHeader,
    ItemTitle,
    } from "@/components/ui/pxl/item";
    export default function ItemHeaderExample() {
    return (
    <div className="flex w-full max-w-xl flex-col gap-6">
    <ItemGroup className="grid grid-cols-3 gap-4">
    <Item variant="outline">
    <ItemHeader>
    <img
    src="https://images.unsplash.com/photo-1650804068570-7fb2e3dbf888?q=80&w=640&auto=format&fit=crop"
    alt="v0-1.5-sm"
    width={128}
    height={128}
    className="aspect-square w-full rounded-sm object-cover"
    />
    </ItemHeader>
    <ItemContent>
    <ItemTitle>v0-1.5-sm</ItemTitle>
    <ItemDescription>Everyday tasks and UI generation.</ItemDescription>
    </ItemContent>
    </Item>
    <Item variant="outline">
    <ItemHeader>
    <img
    src="https://images.unsplash.com/photo-1610280777472-54133d004c8c?q=80&w=640&auto=format&fit=crop"
    alt="v0-1.5-lg"
    width={128}
    height={128}
    className="aspect-square w-full rounded-sm object-cover"
    />
    </ItemHeader>
    <ItemContent>
    <ItemTitle>v0-1.5-lg</ItemTitle>
    <ItemDescription>Advanced thinking or reasoning.</ItemDescription>
    </ItemContent>
    </Item>
    <Item variant="outline">
    <ItemHeader>
    <img
    src="https://images.unsplash.com/photo-1602146057681-08560aee8cde?q=80&w=640&auto=format&fit=crop"
    alt="v0-2.0-mini"
    width={128}
    height={128}
    className="aspect-square w-full rounded-sm object-cover"
    />
    </ItemHeader>
    <ItemContent>
    <ItemTitle>v0-2.0-mini</ItemTitle>
    <ItemDescription>Open Source model for everyone.</ItemDescription>
    </ItemContent>
    </Item>
    </ItemGroup>
    </div>
    );
    }

    Use the render prop to render the item as a link. The hover and focus states will be applied to the anchor element.

    /** biome-ignore-all lint/a11y/useValidAnchor: example */
    import {
    Item,
    ItemActions,
    ItemContent,
    ItemDescription,
    ItemTitle,
    } from "@/components/ui/pxl/item";
    export default function ItemLinkExample() {
    return (
    <div className="flex w-full max-w-md flex-col gap-4">
    <Item
    render={
    <a href="#">
    <ItemContent>
    <ItemTitle>Visit our documentation</ItemTitle>
    <ItemDescription>
    Learn how to get started with our components.
    </ItemDescription>
    </ItemContent>
    <ItemActions>
    <svg
    className="size-4"
    xmlns="http://www.w3.org/2000/svg"
    fill="currentColor"
    viewBox="0 0 24 24"
    >
    <path d="M16 13v-2h-2v2h2Zm-2-2V9h-2v2h2Zm0 4v-2h-2v2h2Zm-2-6V7h-2v2h2Zm0 8v-2h-2v2h2ZM10 7V5H8v2h2Zm0 12v-2H8v2h2Z" />
    </svg>
    </ItemActions>
    </a>
    }
    />
    <Item
    variant="outline"
    render={
    <a href="#" target="_blank" rel="noopener noreferrer">
    <ItemContent>
    <ItemTitle>External resource</ItemTitle>
    <ItemDescription>
    Opens in a new tab with security attributes.
    </ItemDescription>
    </ItemContent>
    <ItemActions>
    <svg
    className="size-4"
    xmlns="http://www.w3.org/2000/svg"
    fill="currentColor"
    viewBox="0 0 24 24"
    >
    <path d="M17 21H5v-2h12v2ZM5 19H3V7h2v12Zm14 0h-2v-6h2v6Zm-8-4H9v-2h2v2Zm2-2h-2v-2h2v2Zm2-2h-2V9h2v2Zm6 0h-2V7h-2V5h-4V3h8v8Zm-4-2h-2V7h2v2Zm-6-2H5V5h6v2Z" />
    </svg>
    </ItemActions>
    </a>
    }
    />
    </div>
    );
    }
    import {
    Avatar,
    AvatarFallback,
    AvatarImage,
    } from "@/components/ui/pxl/avatar";
    import { Button } from "@/components/ui/pxl/button";
    import {
    DropdownMenu,
    DropdownMenuContent,
    DropdownMenuGroup,
    DropdownMenuItem,
    DropdownMenuTrigger,
    } from "@/components/ui/pxl/dropdown-menu";
    import {
    Item,
    ItemContent,
    ItemDescription,
    ItemMedia,
    ItemTitle,
    } from "@/components/ui/pxl/item";
    export default function ItemDropdownExample() {
    return (
    <DropdownMenu>
    <DropdownMenuTrigger
    render={
    <Button variant="outline">
    Select{" "}
    <svg
    xmlns="http://www.w3.org/2000/svg"
    fill="currentColor"
    viewBox="0 0 24 24"
    >
    <path d="M13 16h-2v-2h2v2Zm-2-2H9v-2h2v2Zm4 0h-2v-2h2v2Zm-6-2H7v-2h2v2Zm8 0h-2v-2h2v2ZM7 10H5V8h2v2Zm12 0h-2V8h2v2Z" />
    </svg>
    </Button>
    }
    />
    <DropdownMenuContent className="w-48" align="end">
    <DropdownMenuGroup>
    <DropdownMenuItem>
    <Item size="xs" className="w-full p-2">
    <ItemMedia>
    <Avatar className="size-6.5">
    <AvatarImage
    src="https://raw.githubusercontent.com/pxl-ui/registry/main/app/public/portraits/hero.png"
    className="grayscale"
    />
    <AvatarFallback>H</AvatarFallback>
    </Avatar>
    </ItemMedia>
    <ItemContent className="gap-0">
    <ItemTitle>Hero</ItemTitle>
    <ItemDescription className="leading-none">
    hero@pxl-ui.com
    </ItemDescription>
    </ItemContent>
    </Item>
    </DropdownMenuItem>
    <DropdownMenuItem>
    <Item size="xs" className="w-full p-2">
    <ItemMedia>
    <Avatar className="size-6.5">
    <AvatarImage
    src="https://raw.githubusercontent.com/pxl-ui/registry/main/app/public/portraits/princess.png"
    className="grayscale"
    />
    <AvatarFallback>P</AvatarFallback>
    </Avatar>
    </ItemMedia>
    <ItemContent className="gap-0">
    <ItemTitle>Princess</ItemTitle>
    <ItemDescription className="leading-none">
    princess@pxl-ui.com
    </ItemDescription>
    </ItemContent>
    </Item>
    </DropdownMenuItem>
    <DropdownMenuItem>
    <Item size="xs" className="w-full p-2">
    <ItemMedia>
    <Avatar className="size-6.5">
    <AvatarImage
    src="https://raw.githubusercontent.com/pxl-ui/registry/main/app/public/portraits/wizard.png"
    className="grayscale"
    />
    <AvatarFallback>W</AvatarFallback>
    </Avatar>
    </ItemMedia>
    <ItemContent className="gap-0">
    <ItemTitle>Wizard</ItemTitle>
    <ItemDescription className="leading-none">
    wizard@pxl-ui.com
    </ItemDescription>
    </ItemContent>
    </Item>
    </DropdownMenuItem>
    </DropdownMenuGroup>
    </DropdownMenuContent>
    </DropdownMenu>
    );
    }

    Use the ItemActionsMenu and ItemActionsMenuItem components to display a dropdown with item actions

    • Buy groceries
    • Buy groceries
    • Yoga class
    import { Button } from "@/components/ui/pxl/button";
    import {
    Item,
    ItemActions,
    ItemActionsMenu,
    ItemActionsMenuItem,
    ItemContent,
    ItemGroup,
    ItemSeparator,
    ItemTitle
    } from "@/components/ui/pxl/item";
    export default function ActionItemDemo() {
    return (
    <ItemGroup className="w-full max-w-md has-data-[size=xs]:gap-0">
    <Item variant="default" size="xs">
    <ItemActions>
    <Button
    className="size-4 transition-all animation-duration-1000 hover:animate-pulse"
    size="icon-lg"
    variant="ghost"
    >
    <svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24"><path d="M20 22H4v-2h16v2ZM4 20H2V4h2v16Zm18 0h-2V4h2v16ZM20 4H4V2h16v2Z"/></svg>
    </Button>
    </ItemActions>
    <ItemContent>
    <ItemTitle font="sans">Buy groceries</ItemTitle>
    {/* <ItemDescription>You have a new direct message.</ItemDescription> */}
    </ItemContent>
    <ItemActions>
    <ItemActionsMenu>
    <ItemActionsMenuItem>
    <svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24"><path d="M10 18H8v-2h2v2Zm-2-2H6v-2h2v2Zm4-2v2h-2v-2h2Zm-6 0H4v-2h2v2Zm8 0h-2v-2h2v2Zm2-2h-2v-2h2v2Zm2-2h-2V8h2v2Zm2-2h-2V6h2v2Z"/></svg>
    Complete
    </ItemActionsMenuItem>
    <ItemActionsMenuItem>
    <svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24"><path d="M3 2h18v2H3zm0 5h18v2H3zM1 4h2v3H1zm20 0h2v3h-2zm-2 5h2v11h-2zM3 9h2v11H3zm2 11h14v2H5zm4-9h6v2H9z"/></svg>
    Archive
    </ItemActionsMenuItem>
    <ItemActionsMenuItem variant="destructive">
    <svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24"><path d="M18 22H6V20H18V22ZM9 6H15V4H17V6H22V8H20V20H18V8H6V20H4V8H2V6H7V4H9V6ZM15 4H9V2H15V4Z"/></svg>
    Delete
    </ItemActionsMenuItem>
    </ItemActionsMenu>
    </ItemActions>
    </Item>
    <ItemSeparator className="m-0" />
    <Item variant="default" size="xs">
    <ItemActions>
    <Button
    className="size-4 transition-all animation-duration-1000 hover:animate-pulse"
    size="icon-lg"
    variant="ghost"
    >
    <svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24"><path d="M20 22H4v-2h16v2ZM4 20H2V4h2v16Zm18 0h-2V4h2v16ZM20 4H4V2h16v2Z"/></svg>
    </Button>
    </ItemActions>
    <ItemContent>
    <ItemTitle font="sans">Buy groceries</ItemTitle>
    {/* <ItemDescription>You have a new direct message.</ItemDescription> */}
    </ItemContent>
    <ItemActions>
    <ItemActionsMenu>
    <ItemActionsMenuItem>
    <svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24"><path d="M10 18H8v-2h2v2Zm-2-2H6v-2h2v2Zm4-2v2h-2v-2h2Zm-6 0H4v-2h2v2Zm8 0h-2v-2h2v2Zm2-2h-2v-2h2v2Zm2-2h-2V8h2v2Zm2-2h-2V6h2v2Z"/></svg>
    Complete
    </ItemActionsMenuItem>
    <ItemActionsMenuItem>
    <svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24"><path d="M3 2h18v2H3zm0 5h18v2H3zM1 4h2v3H1zm20 0h2v3h-2zm-2 5h2v11h-2zM3 9h2v11H3zm2 11h14v2H5zm4-9h6v2H9z"/></svg>
    Archive
    </ItemActionsMenuItem>
    <ItemActionsMenuItem variant="destructive">
    <svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24"><path d="M18 22H6V20H18V22ZM9 6H15V4H17V6H22V8H20V20H18V8H6V20H4V8H2V6H7V4H9V6ZM15 4H9V2H15V4Z"/></svg>
    Delete
    </ItemActionsMenuItem>
    </ItemActionsMenu>
    </ItemActions>
    </Item>
    <ItemSeparator className="m-0" />
    <Item variant="default" size="xs">
    <ItemActions>
    <Button
    className="size-4 transition-all animation-duration-1000 hover:animate-pulse"
    size="icon-lg"
    variant="ghost"
    >
    <svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24"><path d="M20 22H4v-2h16v2ZM4 20H2V4h2v16Zm18 0h-2V4h2v16Zm-11-4H9v-2h2v2Zm-2-2H7v-2h2v2Zm4 0h-2v-2h2v2Zm2-2h-2v-2h2v2Zm2-2h-2V8h2v2Zm3-6H4V2h16v2Z"/></svg>
    </Button>
    </ItemActions>
    <ItemContent>
    <ItemTitle font="sans" className="line-through text-muted-foreground">Yoga class</ItemTitle>
    {/* <ItemDescription>You have a new direct message.</ItemDescription> */}
    </ItemContent>
    <ItemActions>
    <Button
    size="icon-xs"
    variant="ghost"
    >
    <svg className="fill-destructive" xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24"><path d="M18 22H6V20H18V22ZM9 6H15V4H17V6H22V8H20V20H18V8H6V20H4V8H2V6H7V4H9V6ZM15 4H9V2H15V4Z"/></svg>
    </Button>
    </ItemActions>
    </Item>
    </ItemGroup>
    );
    }

    The main component for displaying content with media, title, description, and actions.

    Prop Type Default
    variant "default" | "outline" | "muted" "default"
    size "default" | "sm" | "xs" "default"
    render React.ReactElement

    A container that groups related items together with consistent styling.

    <ItemGroup>
    <Item />
    <Item />
    </ItemGroup>

    A separator between items in a group.

    <ItemGroup>
    <Item />
    <ItemSeparator />
    <Item />
    </ItemGroup>

    Use ItemMedia to display media content such as icons, images, or avatars.

    Prop Type Default
    variant "default" | "icon" | "image" "default"
    <ItemMedia variant="icon">
    <Icon />
    </ItemMedia>
    <ItemMedia variant="image">
    <img src="..." alt="..." />
    </ItemMedia>

    Wraps the title and description of the item.

    <ItemContent>
    <ItemTitle>Title</ItemTitle>
    <ItemDescription>Description</ItemDescription>
    </ItemContent>

    Displays the title of the item.

    <ItemTitle>Item Title</ItemTitle>

    Displays the description of the item.

    <ItemDescription>Item description</ItemDescription>

    Container for action buttons or other interactive elements.

    <ItemActions>
    <Button>Action</Button>
    </ItemActions>

    Displays a header above the item content.

    <Item>
    <ItemHeader>Header</ItemHeader>
    <ItemContent>...</ItemContent>
    </Item>

    Displays a footer below the item content.

    <Item>
    <ItemContent>...</ItemContent>
    <ItemFooter>Footer</ItemFooter>
    </Item>