Item

Description

A display or navigation row in a semantic <article> or <a> element.

Usage

bc_item(
  ...,
  title = NULL,
  description = NULL,
  media = NULL,
  actions = NULL,
  href = NULL,
  variant = "default",
  size = "default",
  role = NULL
)

bc_item_group(..., class = NULL, aria_label = NULL)

Arguments

Argument Description
... Tag attributes and any further children, such as a <header> or <footer>, placed after the parts written by the named arguments.
title String or tag. The item's heading, as an <h3>.
description String or tag. Text under the heading.
media Tag or NULL. An icon or image, placed in a leading <figure>.
actions Tag or NULL. A control or indicator, placed in a trailing <aside>.
href String. Link target; when given, the item renders as an <a>.
variant String. One of default, outline, muted. default writes no attribute.
size String. One of default, sm, xs. default writes no attribute.
role String. ARIA role, such as "listitem" inside an item-group.
class String. Extra classes for the group.
aria_label String. Accessible name for the list.

Value

An <article> or <a> tag.

Details

Use bc_field() for form controls; item is for content and navigation.

Examples

bc_item(
  title = "Basic Item",
  description = "A simple item with title and description.",
  actions = bc_button("Action", variant = "outline", size = "sm"),
  variant = "outline"
)

Basic Item

A simple item with title and description.


bc_item(
  title = "Visit our documentation",
  description = "Get started.",
  href = "#"
)

Visit our documentation

Get started.


bc_item_group(
  bc_item(title = "Playground", role = "listitem"),
  bc_item(title = "Models", role = "listitem")
)

Playground

Models