Wizard use case for single step

I’m curious if anyone has a need to support a use case where sometimes a wizard would only have one step. For example, additional steps in the wizard become available based on the options selected by the user in the first step. And these options are only available in the first step if the user has defined some application settings to enable them.

Would the recommendation be to display the wizard with just one step for these users? Has anyone considered a variation of the wizard where the navigation steps aren’t visible until there is more than one step to display?

In the case where the settings aren’t even defined to enable these options, would the recommendation be to continue using a single-step wizard, or would that be a regular modal?


The progressive form design is in progress: https://github.com/patternfly/patternfly-next/issues/1242
That hides steps if they’re not available yet.

I have a use case that I am going to use the progressive form for where step 1 presents a few options to the user. Most of the options will direct the user down different wizard paths but for one option step 2 will be a page saying something like ‘this doesn’t meet your use case, go [here] instead’. (obviously with better words :grin: )
Is something like that close to your use case?

Some application of PF are heavily data driven. The steps in the wizard might be a result of a calculation. The number of the steps can be variable as well.

Unless PF addresses the case when there’s just one step the applications have to deal with it on their own (and each possibly in a different way).

I cannot tell what should be the recommended behavior of having just one step but I am confident that PF should address that case.


@JennGiardino Either the PatternFly Wizard or Progressive Form workflows should handle a situation where all the steps are not known until a decision is made in step one. For the Wizard, see section in the doc labeled Progressive Wizard: https://www.patternfly.org/v4/design-guidelines/usage-and-behavior/wizard If additional steps are not enabled because of the overall configuration, then it seems to make sense to either just revert to a modal or skip the wizard. We did not build in an option to show/hide the steps navigation, but we do have a request to break the wizard into component parts, so in the future it would be possible to create a custom solution that did that. Would that solve this?

Thanks for the feedback! Something that I imagine might be really nice is to have the ability to show/hide the navigation programatically, and have it slide out/in similar to how the main navigation can slide out/in. For example, if there is only one step in the form, don’t show the wizard navigation. But once the user selects something that requires additional steps, the wizard navigation will slide out, using the same animation as the main navigation.

For now, we’re using a single step wizard in our initial implementation. We’ll circle back around at a later time to figure out a refinement to that. I’m not sure that the suggestion to revert to a modal will work in all of our cases. We definitely have cases where we know ahead of time that there will only ever be one step, and could show only a modal. But there are cases where we only have one step unless the user makes certain selections in that first step.

This is different but kind of related to this issue: https://github.com/patternfly/patternfly-next/issues/2198 I think that the wizard sidebar can use some refinements from a couple of perspectives. Feel free to add to that issue. It’s something we can take up as an enhancement in the future.

I captured this use case in the issue.

Thanks, Matt!