Expand description
Stepper / wizard widget.
A horizontal numbered-step progress indicator with connector lines and an accent/muted restyle on step change (segmented-style + progressbar-style filled connector); see stepper.rs.
Stepper / wizard widget — a horizontal multi-step progress indicator: a row
of numbered step circles with labels, joined by connector lines. Completed
and current steps are highlighted in the accent colour; upcoming steps (and
the connectors that lead to them) are muted.
This is a blend of crate::widgets::segmented::Segmented (a horizontal row
of clickable items whose clicked index is derived from sibling position and
whose active item is live-restyled via set_css_property) and the filled-track
look of crate::widgets::progressbar::ProgressBar (the accent connector).
Steps are CLICKABLE (free navigation, like a segmented control): clicking
step i sets current_step = i, invokes the optional on_step_change(state),
and live-restyles every circle / connector / label to reflect the new
position — no DOM rebuild. (A non-clickable, display-only stepper is also a
valid design; this widget chooses clickable to exercise the segmented restyle
pattern, and set_current_step still drives it from app code on rebuild.)
A circle is “reached” (accent) iff its index <= current_step; the connector
gap between circle i and i+1 is accent iff i < current_step. Clicking the
already-current step is a no-op (no callback).
Key types: [Stepper], [StepperState], [StepperOnStepChange].
Structs§
- Stepper
- A horizontal numbered-step progress indicator with a step-change callback.
- Stepper
OnStep Change - Stepper
OnStep Change Callback - Stepper
State - State of a
Stepper: the zero-based current step and the total step count. - Stepper
State Wrapper
Enums§
Statics§
- STEPPER_
ON_ STEP_ CHANGE_ INVOKER - Process-global slot for this callback kind’s host-side invoker.
Functions§
- AzApp_
setStepper OnStep Change Callback Invoker - Register the host-side invoker for this callback kind.
- AzStepper
OnStep Change Callback_ create From Host Handle - C-ABI export wrapping
<Wrapper>::create_from_host_handle.
Type Aliases§
- AzStepper
OnStep Change Callback Invoker - Pointer-arg variant of this callback kind’s typedef.
- Stepper
OnStep Change Callback Type - Callback function type invoked when the current step changes.