Skip to content
Components

Description list

Labelled details, such as record properties.

After the one-time setup, call the helper directly from ERB. No component import is needed.

<%= lc_card class: "w-full" do |card| %>
  <%= card.header title: "Workspace" %>
  <%= lc_description_list do |list| %>
    <%= list.item "Owner", "Ada Baker" %>
    <%= list.item "Plan" do %>
      <%= lc_badge "Team", tone: :primary %>
    <% end %>
    <%= list.item "Created", "March 4, 2026" %>
  <% end %>
<% end %>

Workspace

Owner
Ada Baker
Plan
Team
Created
March 4, 2026
<%= lc_card class: "w-full" do |card| %>
  <%= card.header title: "Workspace" %>
  <%= lc_description_list do |list| %>
    <%= list.item "Owner", "Ada Baker" %>
    <%= list.item "Plan" do %>
      <%= lc_badge "Team", tone: :primary %>
    <% end %>
    <%= list.item "Created", "March 4, 2026" %>
  <% end %>
<% end %>

Helpers render semantic HTML and include their interaction wiring. Pass native attributes through class:, data:, aria: and the usual Rails options. Blocks use captured ERB content.

lc_description_list

lc_description_list(**attributes, &block)
InputDefaultValues
attributes{}Native HTML attributes; class:, data: and aria: merge with defaults
blockCaptured blockCaptured Rails ERB content

lc_description_list yields a builder, list, with these parts. Each part carries data-slot and merges class: and native attributes.

list.item

list.item(term, detail = nil, **attributes, &block)
InputDefaultValues
termRequired—
detailnil—
attributes{}Native HTML attributes; class:, data: and aria: merge with defaults
blockCaptured blockCaptured Rails ERB content

The examples also use lc_card and lc_badge. Each is documented on its own page.

Styling and extension

Use class: to merge utilities, native attributes for application behavior, and the theming guide for the shared palette. For custom markup, the advanced class helpers expose the same styles, including glass surfaces and class merging.

API JSON · LLM reference