previous method

void previous()

Moves to the previous step in the form.

Implementation

void previous() {
  final prevStep = state.currentStep - 1;
  if (prevStep >= 0) {
    state = state.copyWith(currentStep: prevStep);
  }
}