Scroll Flip Card

A scroll-driven sticky card section with 3-D flip animations on desktop and a fly-in stack on mobile. Supports full customization via props with sensible defaults.

Every change leaves a mark.

The Spark
01

The Spark

An idea takes shape — raw, exciting, and full of possibility.

The Build
02

The Build

Turning concepts into reality through code, iteration, and focus.

The Impact
03

The Impact

Experiences that connect, inspire, and leave a lasting impression.

Every idea shapes the world.

Installation

$ npx shadcn@latest add https://akshitr.com/r/scroll-flip-card.json

Usage

import { StickyCards } from "@/components/scroll-flip-card";
 
export default function ScrollFlipCardDemo() {
  return <StickyCards />;
}

Component API

StickyCards

PropTypeDefaultDescription
titlestring"Where are you in your journey?"Heading that fades in over the cards mid-scroll.
introstring"Every change leaves a mark."Text displayed in the intro section before the scroll sequence.
outrostring"Every idea shapes the world."Text displayed in the outro section after the scroll sequence.
cardsStickyCardItem[]See STICKY_CARDS_DEFAULTSArray of card data. Supports 2–4 cards, optimized for 3.
scrollContainerRefObject<HTMLElement>-Optional scroll container ref for custom scroll behavior.
classNamestring-Additional classes applied to the root div.

StickyCardItem

PropTypeDefaultDescription
idstringUnique identifier. Used as the React key.
imagestringURL of the card front-face image.
labelstringMonospaced label rendered top-left of the card back (e.g. "01").
titlestringLarge heading on the card back.
descriptionstringBody text on the card back.
bgcolorstring#1a1a1aCard back background. Accepts any CSS color or var(--token).
textcolorstring#fffCard back text color.
accentcolorstringrgba(255,255,255,0.07)Glow orb color on the card back. rgba recommended for opacity control.