Progress Step (Beta)

lightning:progressStep

Defines a step in lightning:progressIndicator. This component is available in version 41.0 and later.

For Aura components only. For LWC development, use lightning-progress-indicator.

For Use In

Lightning Experience, Experience Builder Sites, Salesforce Mobile App, Lightning Out (Beta), Standalone Lightning App, Mobile Offline

lightning:progressStep is a pilot or beta service that is subject to the Beta Services Terms at Agreements - Salesforce.com or a written Unified Pilot Agreement if executed by Customer, and applicable terms in the Product Terms Directory. Use of this pilot or beta service is at the Customer’s sole discretion.

Note

A lightning:progressStep component specifies a step inside the lightning:progressIndicator component. Specify the label attribute to define the text displayed for the name and tooltip for the step. Specify the value attribute to set the value used to reference the step.

To specify the current step, the currentStep attribute on lightning:progressIndicator must match one of the value attributes on a lightning:progressStep component.

1<aura:component>
2  <lightning:progressIndicator currentStep="step2">
3    <lightning:progressStep label="Step One" value="step1" />
4    <lightning:progressStep label="Step Two" value="step2" />
5    <lightning:progressStep label="Step Three" value="step3" />
6  </lightning:progressIndicator>
7</aura:component>

If the progress indicator type is not specified or is set to base, the label text is displayed in a tooltip when you hover over the step. If the progress indicator type is path, the label is displayed on hover if the step is completed or on the step itself if it’s a current or incomplete step.

This example creates a path showing the current step at “Step Two”. “Step One” is marked completed and “Step Three” is not yet completed.

1<aura:component>
2  <lightning:progressIndicator type="path" currentStep="step2">
3    <lightning:progressStep label="Step One" value="step1" />
4    <lightning:progressStep label="Step Two" value="step2" />
5    <lightning:progressStep label="Step Three" value="step3" />
6  </lightning:progressIndicator>
7</aura:component>

For base type progress indicators, the lightning:progressStep components fire events during user interactions with the steps. Each event returns the index of the step.

This example shows how to get the index of the step that released focus, using the onstepblur event handler.

1<aura:component>
2  <lightning:progressIndicator currentStep="step2">
3    <lightning:progressStep label="Step One" value="step1" onstepblur="{!c.handleStepBlur}" />
4    <lightning:progressStep label="Step Two" value="step2" onstepblur="{!c.handleStepBlur}" />
5    <lightning:progressStep label="Step Three" value="step3" onstepblur="{!c.handleStepBlur}" />
6  </lightning:progressIndicator>
7</aura:component>

The client-side controller:

1({
2    handleStepBlur : function (cmp, evt, helper) {
3        var stepIndex = evt.getParam('index'));
4    }
5})

Usage Considerations 

lightning:progressStep doesn’t support the click event. To enable users to interactively update their progress to the next or previous steps, include a clickable element that updates the currentStep value on lightning:progressIndicator. For more information, see the lightning:progressIndicator documentation.

Accessibility 

Each progress step is decorated with assistive text, which is also the label of that step. For the base type, you can use the Tab key to navigate from one step to the next. Press Shift+Tab to go to the previous step. For the path type, press Tab to activate the current step and use the Up and Down Arrow key or the Left and Right arrow key to navigate from one step to another.

Attributes 

NameDescriptionTypeDefaultRequired
bodyThe body of the component. In markup, this is everything in the body of the tag.Aura.Component[]
classA CSS class for the outer element, in addition to the component's base classes.String
labelText to display as the name or tooltip for the step.String
onstepblurThe action triggered when a step releases focus.Aura.Action
onstepfocusThe action triggered when a step receives focus.Aura.Action
onstepmouseenterThe action triggered when the mouse pointer moves onto the step.Aura.Action
onstepmouseleaveThe action triggered when the mouse pointer moves off the step.Aura.Action
titleDisplays tooltip text when the mouse moves over the element.String
valueText string to reference the step of the progress indicator.String