For the complete documentation index, see llms.txt. Markdown variants are available by appending .md to any URL or sending an Accept: text/markdown header. An agent skill is available at /.well-known/agent-skills/site-skill.md.
/
144
Sponsor

Stepper

A horizontal onboarding stepper with progress animation.

1
Account
2
Plan
3
Done

Installation

$ pnpm dlx shadcn@latest add @framecn/stepper

Usage

import { Stepper } from "@/components/ui/stepper";
<Stepper steps={["Account", "Plan", "Done"]} activeIndex={1} />

Smooth transitions

The docs preview advances through three steps — Account → Plan → Done — via useStepperTransition:

import { Stepper } from "@/components/framecn/stepper";
import { useStepperTransition } from "@/components/framecn/use-stepper-transition";
 
const stepperStyle = useStepperTransition([
  { at: 0, index: 0 },
  { at: 50, index: 1, duration: 24 },
  { at: 110, index: 2, duration: 24 },
]);
 
<Stepper style={stepperStyle} steps={["Account", "Plan", "Done"]} />;

Start explicitly at index 0 so the timeline holds the first step before it fires. Each step ease completes in 24 frames. style takes precedence over activeIndex when both are provided.

API Reference

Stepper

PropTypeDefault
stepsstring[]["Account", "Plan", "Done"]
activeIndexnumber0
styleStepperStyle- (takes precedence over activeIndex)
orientation"horizontal" | "vertical""horizontal"
themePartial<FramecnTheme>-
classNamestring-