Steps

A navigation bar that guides users through the steps of a task.
Importimport{ Steps }from"antd";

When To Use

When a given task is complicated or has a certain sequence in the series of subtasks, we can decompose it into several steps to make things easier.

Examples

Finished
This is a description.
2
In Progress
Left 00:00:08
This is a description.
3
Waiting
This is a description.

The most basic step bar.

CodeSandbox Icon
codepen icon
External Link Icon
expand codeexpand code
Finished
2
In Progress
3
Waiting

By setting like this: <Steps size="small">, you can get a mini version.

CodeSandbox Icon
codepen icon
External Link Icon
expand codeexpand code
Login
Verification
Pay
Done

You can use your own custom icons by setting the property icon for items.

CodeSandbox Icon
codepen icon
External Link Icon
expand codeexpand code
1
First
2
Second
3
Last
First-content

Cooperate with the content and buttons, to represent the progress of a process.

CodeSandbox Icon
codepen icon
External Link Icon
expand codeexpand code
Finished
This is a description.
2
In Progress
This is a description.
3
Waiting
This is a description.

A simple step bar in the vertical direction.

CodeSandbox Icon
codepen icon
External Link Icon
expand codeexpand code
Finished
This is a description.
2
In Progress
This is a description.
3
Waiting
This is a description.

A simple mini version step bar in the vertical direction.

CodeSandbox Icon
codepen icon
External Link Icon
expand codeexpand code
Finished
This is a description
In Process
This is a description
3
Waiting
This is a description

By using status of Steps, you can specify the state for current step.

CodeSandbox Icon
codepen icon
External Link Icon
expand codeexpand code
Finished
This is a description.
In Progress
This is a description.
Waiting
This is a description.
Finished
This is a description. This is a description.
Finished
This is a description. This is a description.
In Progress
This is a description. This is a description.
Waiting
This is a description.
Waiting
This is a description.

Steps with progress dot style.

CodeSandbox Icon
codepen icon
External Link Icon
expand codeexpand code
Finished
You can hover on the dot.
In Progress
You can hover on the dot.
Waiting
You can hover on the dot.
Waiting
You can hover on the dot.

You can customize the display for Steps with progress dot style.

CodeSandbox Icon
codepen icon
External Link Icon
expand codeexpand code
1
Step 1
This is a description.
2
Step 2
This is a description.
3
Step 3
This is a description.
1
Step 1
This is a description.
2
Step 2
This is a description.
3
Step 3
This is a description.

Setting onChange makes Steps clickable.

CodeSandbox Icon
codepen icon
External Link Icon
expand codeexpand code

Navigation steps.

CodeSandbox Icon
codepen icon
External Link Icon
expand codeexpand code
Finished
This is a description.
2
In Progress
Left 00:00:08
This is a description.
3
Waiting
This is a description.

Steps with progress.

CodeSandbox Icon
codepen icon
External Link Icon
expand codeexpand code
Finished
This is a description.
2
In Progress
This is a description.
3
Waiting
This is a description.

Finished
This is a description.
2
In Progress
This is a description.
3
Waiting
This is a description.

Finished
This is a description.
2
In Progress
This is a description.
3
Waiting
This is a description.

Set labelPlacement to vertical.

CodeSandbox Icon
codepen icon
External Link Icon
expand codeexpand code
  • Ant Design Title 1

    Ant Design, a design language for background applications, is refined by Ant UED Team
    Step 1
    This is a Step 1.
    Step 2
    This is a Step 2.
    Step 3
    This is a Step 3.
  • Ant Design Title 2

    Ant Design, a design language for background applications, is refined by Ant UED Team
    Step 1
    This is a Step 1.
    Step 2
    This is a Step 2.
    Step 3
    This is a Step 3.
  • Ant Design Title 3

    Ant Design, a design language for background applications, is refined by Ant UED Team
    Step 1
    This is a Step 1.
    Step 2
    This is a Step 2.
    Step 3
    This is a Step 3.
  • Ant Design Title 4

    Ant Design, a design language for background applications, is refined by Ant UED Team
    Step 1
    This is a Step 1.
    Step 2
    This is a Step 2.
    Step 3
    This is a Step 3.

Inline type steps, suitable for displaying the process and current state of the object in the list content scene.

CodeSandbox Icon
codepen icon
External Link Icon
expand codeexpand code

API

Common props ref:Common props

Steps

The whole of the step bar.

PropertyDescriptionTypeDefaultVersion
classNameAdditional class to Stepsstring-
currentTo set the current step, counting from 0. You can overwrite this state by using status of Stepnumber0
directionTo specify the direction of the step bar, horizontal or verticalstringhorizontal
initialSet the initial step, counting from 0number0
labelPlacementPlace title and description with horizontal or vertical directionstringhorizontal
percentProgress circle percentage of current step in process status (only works on basic Steps)number-4.5.0
progressDotSteps with progress dot style, customize the progress dot by setting it to a function. labelPlacement will be verticalboolean | (iconDot, {index, status, title, description}) => ReactNodefalse
responsiveChange to vertical direction when screen width smaller than 532pxbooleantrue
sizeTo specify the size of the step bar, default and small are currently supportedstringdefault
statusTo specify the status of current step, can be set to one of the following values: wait process finish errorstringprocess
typeType of steps, can be set to one of the following values: default navigation inlinestringdefaultinline: 5.0
onChangeTrigger when Step is changed(current) => void-
itemsStepItem contentStepItem[]4.24.0

type="inline"

PropertyDescriptionTypeDefaultVersion
classNameAdditional class to Stepsstring-
currentTo set the current step, counting from 0. You can overwrite this state by using status of Stepnumber0
initialSet the initial step, counting from 0number0
statusTo specify the status of current step, can be set to one of the following values: wait process finish errorstringprocess
onChangeTrigger when Step is changed(current) => void-
itemsStepItem content. not supported: icon subtitleStepItem[]4.24.0

StepItem

A single step in the step bar.

PropertyDescriptionTypeDefaultVersion
descriptionDescription of the step, optional propertyReactNode-
disabledDisable clickbooleanfalse
iconIcon of the step, optional propertyReactNode-
statusTo specify the status. It will be automatically set by current of Steps if not configured. Optional values are: wait process finish errorstringwait
subTitleSubtitle of the stepReactNode-
titleTitle of the stepReactNode-

Design Token

Component TokenHow to use?

Token NameDescriptionTypeDefault Value
customIconFontSizeFont size of custom iconnumber24
customIconSizeSize of custom icon containernumber32
customIconTopTop of custom iconnumber0
descriptionMaxWidthMax width of description areanumber140
dotCurrentSizeCurrent size of dotnumber10
dotSizeSize of dotnumber8
iconFontSizeSize of iconnumber14
iconSizeSize of icon containernumber32
iconSizeSMSize of small steps iconnumber24
iconTopTop of iconnumber-0.5
navArrowColorColor of arrow in navstringrgba(0,0,0,0.25)
navContentMaxWidthMax width of nav contentundefined | MaxWidth<string | number>auto
titleLineHeightLine height of titlestring | number32

Global TokenHow to use?