ReactHive

Step Stack

Cards 20

About

A process told as a deck. A giant line slides across a pinned screen while the steps rise from below one at a time, curled back, and unroll flat onto the pile with a spring. Earlier steps stay underneath, each stepping up and dimming, and the deck leans with your scroll.

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

Code

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

Usage.tsx

"use client";

import { StepStack, type Step } from "@/components/ui/step-stack";

const settings = {
  tint: "#0a45ff",
  curl: 110,
  bounce: 0.5
};

/* The demo's Google Fonts. In a Next.js app, use next/font/google instead. */
if (typeof document !== "undefined" && !document.getElementById("step-stack-fonts")) {
  const style = document.createElement("style");
  style.id = "step-stack-fonts";
  style.textContent = "@import url('https://fonts.googleapis.com/css2?family=Host+Grotesk:wght@300..800&display=swap'); .rh-host-grotesk { font-family: 'Host Grotesk', sans-serif; }";
  document.head.appendChild(style);
}

const sans = { className: "rh-host-grotesk", style: { fontFamily: "'Host Grotesk', sans-serif" } };

const ITEMS = [
  { title: "Quick Intro", line: "A short call, no slides." },
  { title: "Scope Check", line: "We say no if it isn't a fit." },
  { title: "One Lead", line: "A single person runs your project." },
  { title: "Your Tools", line: "We work where you already work." },
  { title: "You Own It", line: "Code, files and accounts are yours." },
];

const STEPS: Step[] = ITEMS.map((s, i) => ({
  label: `Step ${i + 1} of ${ITEMS.length}: ${s.title}. ${s.line}`,
  content: (
    // Coloured through the --step-* variables, so the copy filled with the light gets white type on blue.
    <div className="h-full w-full bg-[var(--step-bg,#fff)] text-[var(--step-ink,#0a0a0b)] [container-type:size]">
      <div className="flex h-full flex-col px-[8cqw] pt-[11cqw] pb-[8cqw]">
        {/* A big light numeral, the step's own mark. */}
        <span className="text-[30cqw] leading-[0.78] font-light tracking-[-0.07em] text-[var(--step-accent,#0a45ff)]">{String(i + 1).padStart(2, "0")}</span>
        <span className="mt-auto text-[9cqw] leading-[1.02] font-medium tracking-[-0.035em]">{s.title}</span>
        <span className="mt-[2.5cqw] text-[4.6cqw] leading-[1.35] text-[var(--step-mute,#6e6e73)]">{s.line}</span>
        {/* Where you are: one segment per step, filled up to this one. */}
        <span className="mt-[7cqw] flex gap-[1.6cqw]">
          {ITEMS.map((_, j) => (
            <span key={j} className="h-[1.1cqw] flex-1 rounded-full" style={{ background: j <= i ? "var(--step-accent, #0a45ff)" : "var(--step-track, rgba(10,10,11,0.1))" }} />
          ))}
        </span>
      </div>
    </div>
  ),
}));

function DemoContent(props: Partial<typeof settings> = {}) {
  const v = { ...settings, ...props };

  return (
    <main className={`${sans.className} bg-white text-white`}>
      <StepStack
        steps={STEPS}
        marquee="How It Works"
        tint={String(v.tint)}
        curl={Number(v.curl)}
        bounce={Number(v.bounce)}
        marqueeClassName="text-[clamp(5rem,13vw,13rem)] leading-none font-light tracking-[-0.045em] text-white/90"
      >
        {/* The night band, with a low blue light under the deck. */}
        <div className="absolute inset-0 bg-[#040a26]" />
        <div className="absolute inset-x-[-20%] bottom-0 h-[70svh] bg-[radial-gradient(50%_60%_at_50%_100%,rgba(10,69,255,0.45),rgba(10,69,255,0.12)_50%,transparent_80%)]" />
      </StepStack>
      <section className="flex min-h-[50svh] items-center justify-center px-5 text-center text-[#0a0a0b]">
        <p className="text-[clamp(2rem,4vw,2.75rem)] leading-[1.09] font-medium tracking-[-0.025em]">
          Five Steps. <span className="text-[#6e6e73]">Then We Build.</span>
        </p>
      </section>
    </main>
  );
}

/** The demo in its own colours, filling the frame. */
export default function Demo(props: Partial<typeof settings> = {}) {
  return (
    <div className="min-h-svh w-full" style={{ background: "#040a26" }}>
      <DemoContent {...props} />
    </div>
  );
}

More by ReactHive

View all
  • Card Deal

    Card Deal

    20
  • Card Pack

    Card Pack

    12
  • Arc Gallery

    Arc Gallery

    9
  • Fluid Type

    Fluid Type

    7
  • Shoal

    Shoal

    7
  • Satin

    Satin

    6
  • Mercury Clock

    Mercury Clock

    3
  • Whirlwind

    Whirlwind

    2

More in Cards

View all
  • Course Design Cards

    Course Design Cards

    1.3K
  • Weather Card

    Weather Card

    68
  • Statistics Card 7

    Statistics Card 7

    339
  • Stats cards with links

    Stats cards with links

    102
  • Statistics Card 2

    Statistics Card 2

    316
  • Approval Card

    Approval Card

    37
  • Statistics Card 10

    Statistics Card 10

    306
  • Recipe Card

    Recipe Card

    52

Explore more

Part of ReactHive UI — browse the full library on 21st.dev.