StepProgressIndicator

public struct StepProgressIndicator
extension StepProgressIndicator: View
extension StepProgressIndicator: _ViewEmptyChecking

StepProgressIndicator is a view supporting a list of StepItem in a horizontal stack. Also customized steps are also supported.

Usage

@State var selection: String = "id"
var steps: [StepItem] = []
StepProgressIndicator(selection: self.$selection,
                      stepItems: self.steps)
Also indexed view builder is also supported.
StepProgressIndicator(title: <#T##() -> any View#>, action: <#T##() -> any View#>, cancelAction: <#T##() -> any View#>, selection: <#T##Binding<String>#>, steps: <#T##() -> any IndexedViewContainer#>)

You can also update step style for different states, if you created StepProgressIndicator by [StepItem]. func stepStyle(_ style: @escaping ((_ id: String) -> (some StepStyle)?)) -> some View