Skip to content
Black FridayBlack Friday launch price: Lifetime $149 until 30 Nov. Regular price $299 from 1 Dec.ends in 15d 03:13:34Get Lifetime →
loopkit
proNew138 lines · framer-motion

Scroll Card Fan

A stack that opens up as you read. A full-width, pinned scroll section where a neat stack of cards fans open like a hand of cards as the section's scroll progress advances, and folds back up on the way out.

Use it for
Showing four or five related stats or highlights with a satisfying, tactile reveal instead of a plain row.
Themes
Light + dark
License
Commercial use
Live

One deck, five numbers

A stack that opens up as you read

Latency

82ms

Uptime

99.98%

Coverage

41 regions

Incidents

0 this week

Cost

-18% MoM

tsx
"use client";

import * as React from "react";
import { motion, useMotionValue, useReducedMotion, useScroll, useTransform, type MotionValue } from "framer-motion";
import { cn } from "@/lib/utils";

function useReducedMotionSafe() {
  const prefersReduced = useReducedMotion();
  const [mounted, setMounted] = React.useState(false);
  React.useEffect(() => setMounted(true), []);
  return mounted ? !!prefersReduced : false;
}

/**
 * Full-width scroll section: a neat stack of cards fans open like a hand of
 * playing cards as the section's own scroll progress advances, and folds
 * back up if you scroll back.
 */

export interface FanCard {
  label: string;
  value: string;

The rest is in Pro.

Full source, the rebuild prompt and registry install unlock with Pro or Lifetime.

Get Pro

How it behaves

  • →Every card's rotation, horizontal offset and vertical lift are computed from the same shared, section-scoped progress value, offset by how far each card sits from the centre of the deck.
  • →At rest the deck is either fully closed or partway open depending on the current progress — both are valid, composed states.
  • →autoplay sweeps progress from closed to open and back on a timer, so the fan motion is visible without any real scrolling.
  • →Z-index favours cards closer to the centre, so the fan reads correctly from any progress value.
  • →prefers-reduced-motion settles the deck in a mostly-open resting position with no further animation.

Accessibility

  • ✓Cards stay in their natural DOM order regardless of visual fan position.
  • ✓Each card's label and value are plain text, not colour-only information.
  • ✓Honours prefers-reduced-motion by freezing the fan.
  • ✓Honours prefers-reduced-motion.