Tony Sebastian

Image Stack

Cards 422

About

An interactive image stack component that displays images in a fanned-out card layout with smooth drag-to-cycle functionality. Built with React, Motion, and Next.js Image optimization.

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Image Stack to your project and fits it to your theme.

Code

How Image Stack is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

import ImgStack from "@/components/ui/image-stack";

export default function DemoOne() {
  const imageUrls: string[] = [
    'https://res.cloudinary.com/dctgknnt7/image/upload/v1758731403/1_d8uozd.jpg',
    'https://res.cloudinary.com/dctgknnt7/image/upload/v1758731402/5_ionpyy.jpg',
    'https://res.cloudinary.com/dctgknnt7/image/upload/v1758731402/4_zeoqje.jpg',
    'https://res.cloudinary.com/dctgknnt7/image/upload/v1758731402/3_nfdtim.jpg',
    'https://res.cloudinary.com/dctgknnt7/image/upload/v1758731402/2_hme6yu.jpg',
  ];

  return (
    <main className="w-full p-6 flex">
      <div className="w-full flex-1">
        <div className="h-full flex items-center justify-center">
          <ImgStack images={imageUrls} />
        </div>
      </div>
    </main>
  )
}

Dependencies

More by Tony Sebastian

View all
  • Img Sphere

    Img Sphere

    2K
  • Image loading

    Image loading

    614
  • Image Sphere

    Image Sphere

    479
  • Comet Hero

    Comet Hero

    113

More in Cards

View all
  • Card

    Card

    70
  • Statistics Card 2

    Statistics Card 2

    263
  • Stats cards with links

    Stats cards with links

    39
  • Course Design Cards

    Course Design Cards

    1.1K
  • Card Studio

    Card Studio

    7
  • The Item one

    The Item one

    3
  • Statistics Card 7

    Statistics Card 7

    290
  • Dashboard with Collapsible Sidebar

    Dashboard with Collapsible Sidebar

    2.4K