DocsGitHub
Getting Started
  • Overview
  • Design Tokens
Components
  • Accordion
  • Alert
  • Announcement
  • Avatar
  • Badge
  • BigCalendar
  • Breadcrumb
  • Button
  • ButtonGroup
  • Calendar
  • Card
  • Checkbox
  • Chip
  • CloseButton
  • Combobox
  • CommandPalette
  • ContextMenu
  • Currency
  • DatePicker
  • DescriptionList
  • Drawer
  • DropdownMenu
  • EmptyState
  • Field
  • FileUpload
  • FormGrid
  • Hotkey
  • Icon
  • Input
  • Metric
  • Modal
  • MultiSelect
  • NumberInput
  • Pagination
  • Popover
  • ProgressBar
  • Radio
  • Rating
  • SegmentedControl
  • Select
  • SelectionCard
  • Sidebar
  • Skeleton
  • Slider
  • Spinner
  • Stepper
  • Switch
  • Table
  • Tabs
  • Textarea
  • Timeline
  • TimePicker
  • Toast
  • Tooltip
  • TransferList
  • TreeView
  • Wizard
Charts
  • Overview
  • Area Chart
  • Bar Chart
  • Donut Chart
  • Line Chart
  • Pie Chart
  • Stacked Bar Chart

Stepper

A visual step indicator that shows progress through a multi-step process.

Installation

tsx
import { Stepper, StepperStep } from "madagent";

Basic

AccountStep 1: Account (completed)
2ProfileStep 2: Profile (current)
3ReviewStep 3: Review

With Description

AccountCreate your accountStep 1: Account (completed)
2ProfileSet up your profileStep 2: Profile (current)
3BillingAdd payment methodStep 3: Billing
4ConfirmReview and submitStep 4: Confirm

Custom Icons

AccountStep 1: Account (completed)
SettingsStep 2: Settings (completed)
BillingStep 3: Billing (current)
SecurityStep 4: Security

Vertical

Create accountEnter your email and choose a password.Step 1: Create account (completed)
2Personal infoTell us your name and date of birth.Step 2: Personal info (current)
3Choose planSelect a subscription that fits your needs.Step 3: Choose plan
4ConfirmationReview your details and confirm.Step 4: Confirmation

Sizes

AccountStep 1: Account (completed)
2ProfileStep 2: Profile (current)
3DoneStep 3: Done
AccountStep 1: Account (completed)
2ProfileStep 2: Profile (current)
3DoneStep 3: Done
AccountStep 1: Account (completed)
2ProfileStep 2: Profile (current)
3DoneStep 3: Done

Interactive

Error State

UploadSelect your filesStep 1: Upload (completed)
ValidateChecking file formatStep 2: Validate (error)
3ProcessGenerating outputStep 3: Process

Stepper

PropTypeDefaultDescription
activeStep
number
0Index of the currently active step (0-based)
orientation
"horizontal""vertical"
"horizontal"Layout direction of the stepper
size
"sm""md""lg"
"md"Size of the step indicators
onStepClick
(index: number) => void
-Callback when a step is clicked. If provided, steps become interactive buttons.
children
ReactNode
-StepperStep elements

StepperStep

PropTypeDefaultDescription
label
string
-Step title
description
string
-Optional subtitle below the label
icon
ReactNode
-Custom icon — overrides the default number or checkmark
error
boolean
falseDisplays the step in an error state

RTL Support

Components automatically adapt to right-to-left languages using CSS logical properties.

Preview

الحسابأنشئ حسابكStep 1: الحساب (completed)
2الملف الشخصيأكمل بياناتكStep 2: الملف الشخصي (current)
3التأكيدراجع وأرسلStep 3: التأكيد

Usage

tsx
<Stepper activeStep={1} dir="rtl">
  <StepperStep label="الحساب" description="أنشئ حسابك" />
  <StepperStep label="الملف الشخصي" description="أكمل بياناتك" />
  <StepperStep label="التأكيد" description="راجع وأرسل" />
</Stepper>