Products, rows


Install
npx shadcn add @klarhimmel/products-rowsDetailsAbout, usage, props and more
A heading over full-width ruled rows, each with a small square picture, a name, one line, a price and a button at the right.
Import
Import
- products/rows
- About
- A heading over full-width ruled rows, each with a small square picture, a name, one line, a price and a button at the right. The heading can instead sit beside a large picture with plain rows (name, label, line, price) and actions below.
- Category
- Things for sale as cards, rows or one featured item, each with a name, a price and its own action. New project? Set it up once: /get-started/installation.
Notes
When to use it
Pick it for a priced list where every row is one offer: a small square picture, a name, one line, a price and a button at the right, or, with layout beside, a large picture next to the heading and plain rows. For cards in a grid pick pricing-split-rows or features-image-cards.
Writing for it
- Name up to 60 characters, line up to 160, price up to 16, period up to 40, badge up to 24. - One to eight rows. A price default is a placeholder like 00, write the real figure. - Rows list hides the picture and button; the beside layout shows the actions under the rows.
Watch out for
A row with no button link still draws, so give each pictured row its own action or the right side looks empty. Long names push the price down on a phone, keep names to one line.
Pairs well with
Usage
The block in a page, with its default content (long lists shortened). Every prop is in the table below.
Props
The type, default and text limit of every prop. On a real page, over-limit text is kept and checkSections flags it (Installation, Check a page before you ship); this live preview shows the default until it fits. The panel above edits all props.
| Prop | Type | Default | Description |
|---|---|---|---|
eyebrow | string | '' | Text, up to 60 characters. |
title | string | 'Say what the items below have in co…' | Text, up to 120 characters. |
description | string | '' | Text, up to 240 characters. |
layout | 'stacked' | 'beside' | 'stacked' | One of 'stacked', 'beside'. |
rows | 'pictured' | 'list' | 'pictured' | One of 'pictured', 'list'. |
media | Media | {…} | See the type. |
items | { name, description, price, period, badge, media, action }[] | 3 items | List of 1 to 8. Each item: name, description, price, period, badge, media, action (optional). |
primary | Link | - | Optional; empty is not rendered. |
secondary | Link | - | Optional; empty is not rendered. |
textLink | Link | - | Optional; empty is not rendered. |
headingLevel | '1' | '2' | - | One of '1', '2'. Optional; empty is not rendered. |