Product listing
ProA filterable grid of products with sort and a result count.
pnpm dlx shadcn@latest add @caliper/product-listing6 of 6 products
Linen overshirt
★ 4.7 (212)
$89Canvas tote
★ 4.5 (98)
$34Merino beanie
★ 4.8 (311)
$28Only 2 left
Leather weekender
★ 4.9 (57)
$240Sold outCeramic mug set
★ 4.4 (140)
$46Wool throw
★ 4.6 (76)
$120
When to use #
Use it for
- A shop page where people browse and narrow a catalogue.
- Filters and sorting share the page.
Skip it when
- You show a single product; use product detail.
Installation #
pnpm dlx shadcn@latest add @caliper/product-listing
Adds its 6 files to components/ui/, each with its own stylesheet, and installs their packages. Pro installs with your access token, set up once per project. See Pro access. The first part also adds Caliper UI’s tokens; import them once as in Installation.
Usage #
Import it from your copy of the source. The example behind the preview comes with the source.
import { ProductListing } from "@/components/ui/product-listing"
The worked example comes with Pro
The 24-line example behind the preview opens here with a Pro or Team licence.
API reference #
ProductListing
component
Accessibility #
It exposes group and status semantics, with aria-label, aria-pressed and aria-hidden kept in step with state. Changes that matter are announced through a live region.
Keyboard and focus handling comes from Radix popover: arrow keys move through items, Enter and Space select, and Escape closes and returns focus.
Motion #
It declares no animation in its component source. Any transition comes from its stylesheet, which uses the duration tokens that collapse to instant under prefers-reduced-motion.