Skip to content
shadcn.io

shadcn.io is not affiliated with official shadcn/ui

Fanned Card Deck Features Block for React

Five playbook cards stacked and pivoting from their bottom edge that spread on an arc on hover, on focus inside the deck or when a Fan out toggle is pressed, each with a small drawing of its play.

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 fanned card deck features section for React with Base UI. Five cards of a sales-playbook tool sit stacked with a slight offset and pivot from their bottom edge. Hovering the deck, moving focus into it or pressing the "Fan out the deck" toggle spreads them on an arc, so each card's title and drawing is in view (a call-script line, two question chips, an objection and its answer, a demo timer, a booked slot). A card lifts under the pointer so its sentence can be read, and a hairline floor sits under the hand. It's built from Toggle and Guides, with CSS rotation and translation driven by one custom property and your theme's tokens for every colour. For playbooks, onboarding steps and any set of five things that belong in one hand.

FAQ

How does the fan work?

The deck sets a custom property, --f, to 0 at rest and 1 when it is hovered, has focus inside it or has the toggle pressed. Each card reads its place in the hand from --k (from minus two to two) and sets its rotate and translate from both, so one CSS transition spreads them all. There is no script on the cards themselves.

How do I change the cards?

Edit PLAYS (a title and a sentence each) and the five drawings above Card. The pose maths assumes five cards, with the middle one at zero; for another count change at() so the middle card is still zero, and the width of the stage.

How does it work without a mouse?

The Fan out toggle is a real button with a pressed state, so a keyboard or a touch screen can open the fan and keep it open. Focus on the toggle also spreads the deck while it has focus. On a touch device, where there is no hover, the toggle is the way in.

What does a screen reader hear?

Every card is in the reading order as a heading with its sentence, whether the deck is fanned or not; the drawings are hidden from assistive technology. Stacked cards overlap on screen only.

What happens with reduced motion?

The fan and the lift transitions are off, so the cards jump between stacked and spread. Nothing plays by itself.

How does it fit on a phone?

The cards are narrower and the arc is shallower, so the fan fits inside 320 pixels. Each card's title strip shows when fanned, and a card's sentence is readable on the front card and on whichever card you lift.

  • Pro

    A centred showcase hero for a reporting workspace: the headline and a Shine Button, then a band between the rails with a fanned deck of three app windows (Dashboard, Analytics, Reports) that runs off its foot, masked.

  • Pro

    A stack of six flashcards with one large front card and three peek cards above it at shrinking scale; Next card sends the front card to the back and clicking a peek brings it forward, beside three features.

  • Pro

    A wallet-style stack of five studio contact cards built on a single-open Accordion: the cards overlap so only each title strip shows, and opening one slides it forward and reveals its details.

  • Pro

    3D Ring Carousel Features

    Carousels and media

    Six capability cards on a true 3D ring in a framed stage, turned a card at a time by the previous and next buttons or the arrow keys, with the far cards dimming behind the front one.

  • Pro

    A static row of four spec cards for a component library: a drawing, a type line, a rule sentence, a spec link and a stat tab with two numbers, raised on hover or focus.

  • Pro

    An exploded isometric stack of three greyscale planes (data, logic, view) in CSS 3D, with a ruled list of the layers beside it: hovering, focusing or tapping a layer lifts its plane and outlines it.