New York
01 / 05A little more warmth
Soft light settles across the frame while an open horizon leaves room for the story to unfold. The colors shift gently as this portrait approaches the center.
A scroll-scrubbed image story where cards travel along a shallow arc and continuously shape the scene around the centered frame.
Portraits / visual story
Scroll to explore
The frame at the center shapes the image, color, and story.
Document scroll progress continuously moves cards upward along a shallow arc. The card nearest the center influences the displayed story and interpolated scene color; scrolling backward reverses the same timeline.
Cards include configurable image alt text and semantic CTA links. Reduced-motion preferences soften the curved movement and depth transforms while preserving the scroll sequence.
The pinned scene occupies the configured scroll distance. Use a shorter distance for compact pages, and provide image alt text and at least two cards for a meaningful transition.
Choose the CLI command or install the component manually.
$ npx @istmx/ui add scroll-story-cardsCopies the install command for your selected package manager.
Dependencies
Import the component from the file you copied it to, then use it like any other React component.
import ScrollStoryCards, { type ScrollStoryCard } from '@/components/ui/scroll-story-cards' const cards: ScrollStoryCard[] = [ { id: 'coast', eyebrow: 'South coast', title: 'The coast', description: 'A slower frame at the edge of the water.', image: '/images/coast.jpg', imageAlt: 'A quiet coastline in late afternoon light', color: '#e8e0f4', overlayColor: '#cbbce5', overlayOpacity: 0.34, buttonLabel: 'Explore', buttonHref: '/coast', }, // Add more cards with their own images and colors.] <ScrollStoryCards cards={cards} eyebrow="Selected stories" heading="A collection worth exploring." description="Move through the frames by scrolling." curveAmount={64} cardWidth={156} cardHeight={156} overlayOpacity={0.38} scrollDistance={400}/>ScrollStoryCards├── Sticky story scene│ ├── Fixed heading and eyebrow│ ├── Rising image cards with copy and CTA│ └── Five-card waiting stack└── Natural scroll releasecardsScrollStoryCard[]Cards with id, optional eyebrow, title, description, image, imageAlt, and a hex color for the scene background. overlayColor optionally tints the image and defaults to color; buttonColor defaults to overlayColor or color.
eyebrow? / heading? / description?stringFixed scene label, heading, and optional supporting copy shown above the changing card content.
className?stringClasses applied to the outer scroll section.
curveAmount?numberHorizontal curve width in pixels as a card moves toward and away from the center. Defaults to 64.
cardWidth? / cardHeight?numberMaximum square size in pixels for the separated waiting previews. Defaults to 156px; featured cards cap at 620px wide and 17rem high on desktop.
overlayOpacity?numberDefault color-overlay opacity from 0 to 1. Defaults to 0.38.
scrollDistance?numberPinned story timeline in viewport units. Defaults to 400vh, then releases directly into following page content.
scrollContainerRef?RefObject<HTMLElement | null>Optional scrollable ancestor for embedded previews. Omit it to track the document scroll position.
showCardLabels?booleanShow each moving card title. Defaults to true.
onActiveChange?(card: ScrollStoryCard) => voidCalled when a different card is nearest the center. Continuous visual motion remains scroll-linked.
The listed props match the current component implementation.
Scroll Story Cards does not expose custom data attributes.
Use at least two cards to see color and image blending. Scroll position continuously moves the nearest card through the center; stopping or reversing preserves the exact intermediate state. Cards require imageAlt text and may include CTA links.
Created by Aryan (istmX) for ISTMX. The source-first, copy-and-own philosophy is inspired by shadcn/ui. About the creator