Skip to content
shadcn.io

shadcn.io is not affiliated with official shadcn/ui

Masonry Mixed Height Cards Features Block for React

A masonry wall of six cards of different heights for a team workspace: a checklist whose boxes really tick, a quick-add bar, a stat, a three-lane board, a set of tags and a thread with a mention.

Framework
UI library

Preview

Preview width

Installation

Part of Pro
Pro unlocks the code and one-line install of every Pro button and text effect, plus the MCP for your AI editor.
Have Pro already? Sign in to open it.Opens here as soon as you're Pro.

Overview

A masonry feature section for React with Base UI, written for Patchwork, a fictional team workspace. Six cards flow down three columns (two from sm, one on a phone) in CSS columns, so each is exactly as tall as its content, and each is its own box with its lines running past the corners and a + mark on each. Every card is a different small piece of the product: a launch checklist whose Checkboxes really tick and whose Progress bar and count follow them, a quick-add bar with its key, a stat that rolls, a three-lane board, a set of tags and a thread with a mention. The header holds a text link with an arrow that mirrors in right-to-left pages. It is built from Guides, Checkbox, Field, Progress, Avatar, Badge, Kbd and Sliding Number with CSS only and your theme's tokens. For workspace and productivity products that are a set of parts, not a single screen.

FAQ

In what order are the cards read and tabbed?

In the order of the list, which is the order the columns fill: the first card tops the first column and the list runs down it, then down the next. Reading and keyboard order are therefore the DOM order. The defaults are listed so three columns come out about level, so with a different set of cards, reorder the list until they do. Changing the number of columns changes where later cards land, never their order.

How does the checklist work?

It keeps the ticked tasks in state. Each task is a Checkbox named by its own label, so clicking the label or the box toggles it and a screen reader hears "Record the demo, checkbox, checked". The progress bar and the "3 of 7 done" count, a polite status line, are derived from the same list. Edit TASKS and STARTED to change the tasks and what begins ticked.

How do I add or change a card?

Add a Card with a title, a description and a small component as its child, and make sure the list stays a flow of cards: they use break-inside-avoid so none splits across columns. Heights come from content, so a taller card simply makes its column longer.

How do screen readers and keyboards handle it?

The section has an h2, each card is a list item with an h3, and the only controls are the checklist's Checkboxes and the header link. The other pieces (the quick-add bar, the board, the tags, the thread) are drawings, hidden from assistive technology and not focusable, and each card's sentence says what it shows.

How does it fit on a phone?

The wall is one column below sm and two from sm, three from lg. Cards keep their natural height, and nothing scrolls sideways at 320 px.

What moves, and what happens with reduced motion?

The header fades up once on load, the checklist's progress bar eases to its new width and the stat's digits roll, all with CSS transitions. With reduced motion they are off and everything changes in place.

  • Pro

    A bento of six kinds of cell for a field-service app, each a box with its lines running past the corners: a job list, a rolling figure, avatars with presence, a code window, live switches and a step tracker.

  • Pro

    A six-cell report-type grid for a reporting tool: a trend line, a table, a funnel, a ranked list, a heat strip and a donut, each drawn on a 4:3 plate above its title and one sentence.

  • Pro

    Six ring-inset preference cells for a team-settings app, each holding one working control: a switch, a slider, a toggle group, a select, a checkbox and a segmented control.

  • Pro

    A showcase hero for a design studio: a centered headline with a Shine Button, over a masonry wall of six projects drawn in greyscale inside a hairline frame that fades out at its foot.

  • Pro

    A bento for a docs-publishing platform with one flagship cell, a page editor drawn in greys with a pulsing Published status, beside a build-time stat and a version list, over three small cells, in one rounded outline of shared hairlines.

  • Pro

    A bento of five features for an issue tracker, each cell drawn as the product at work: a live board with teammates' cursors, a pull request, a burndown, a triage rule and a typed SDK, in cells that share their hairlines.