shadow
The Stepper component displays the progress through numbered steps. It provides a wizard-like workflow.
Steppers show progress through a sequence of numbered steps.
Use wje-stepper when users need to enter values, choose options, or trigger form-related actions.
Do not use it as a decorative element without interaction. Prefer presentational components in that case.
Always provide a label (label/aria-label), keep keyboard support, and surface clear validation feedback.
- Keep validation rules and error behavior consistent across the entire form.
- Show loading or disabled states during async operations.
- Split complex forms into smaller sections with immediate feedback.
| Description | The active color for the stepper. |
| Attribute | active |
| Type | string |
| Default | - |
| Description | The done color for the stepper. |
| Attribute | done |
| Type | string |
| Default | - |
No events available for this component.
| Description | Processes the current step and updates stepper state and navigation. |
| Signature | (index: any, step: any, header: any, steps: any) => void |
| Description | Navigates to a different step in a multi-step process based on the provided direction. |
| Signature | (direction: number) => void |
| Description | Navigates to a specific step in a workflow or process. Executes a set of operations before and after the step transition. |
| Signature | (stepIndex: number) => void |
| Description | Resets a step to its default state by clearing its active and done attributes. Updates the step's badge to show its index and removes any color styling. |
| Signature | (nav: HTMLElement, badge?: HTMLElement|null, stepIndex?: number) => void |
| Description | Sets a step as active by adding the active attribute and updating the step's badge. |
| Signature | (nav: HTMLElement, badge?: HTMLElement|null, stepIndex?: number|null) => void |
setContentActive
| Description | Activates the content of a specific step by displaying it and hiding all others. |
| Signature | (stepIndex: number) => void |
| Description | Returns the DOM element of a step by index. |
| Signature | (stepIndex: number) => HTMLElement |
renderStepContent
| Description | Appends or replaces content inside the step container. |
| Signature | (stepIndex: number, content: Node|string|Node[], options?: \{ replace?: boolean \}) => void |
| Description | Marks a step as completed by setting the done attribute and updating its badge with a check icon. |
| Signature | (nav: HTMLElement, badge?: HTMLElement|null) => void |
| Description | Sets step locked and applies related state updates. |
| Signature | (nav: any, badge: any) => void |
| Name | Description |
|---|
native | The native part of the stepper. |
header | The header part of the stepper. |
content | The content part of the stepper. |
No CSS custom properties available for this component.
| Name | Description |
|---|
default | The default slot for the stepper. |