mdl-stepper icon indicating copy to clipboard operation
mdl-stepper copied to clipboard

Stepper reset

Open DennisBlock opened this issue 9 years ago • 2 comments

Hi,

I'm using the stepper in a dialog, which I have to use more than once. Is there a way to reset the state of the stepper?

Thanks

DennisBlock avatar Sep 09 '16 12:09 DennisBlock

You can describe your case and explain what should be understood as reset the state?

axdemelas avatar Sep 09 '16 18:09 axdemelas

I'm using a Gantt chart to display different tasks. To create a new task a dialog opens which contains the (non-linear) stepper. After filling out the form in each step the dialog closes automatically (using the steppers 'onsteppercomplete' event) and creates the new task. Now if the user wants to create another task (same page, no redirect or anything like that), the same dialog opens, but the stepper is already completed. I'm clearing all form elements, thats not the problem, but each step is marked as completed (checkmark) and the stepper starts with the last step. The same thing happens if I click on 'cancel' and the dialog closes. The next time I'm opening the dialog, it starts from where i left earlier.

So i need something that tells the stepper to start from the beginning with each step marked as uncomplete. This is what I mean with reset.

DennisBlock avatar Sep 10 '16 14:09 DennisBlock