Skip to content

feat: add multi-step wizards with conditional steps and a review screen - #2

Merged
autoantohaki merged 1 commit into
feat/promptsfrom
feat/wizard
Oct 22, 2026
Merged

autoantohaki merged 1 commit into
feat/promptsfrom
feat/wizard

Conversation

@autoantohaki

Copy link
Copy Markdown
Member

Requested by mau

Before: a setup flow with more than a handful of questions was one long list, Esc cancelled everything, and there was no way to skip questions that did not apply or to check the answers before committing to them.

After: runWizard splits a flow into steps with a progress row (✔ Project · › Tooling · Publish · Review). Steps can be skipped with when or build their fields from earlier answers, Esc walks back through questions and steps with answers kept, and a review screen lists everything with a Change … entry per step. npm run demo -- wizard shows it.

Stacked on #1 (base feat/prompts); merge that first and GitHub will retarget this to main.

How: Wizard tracks the answers, the completed steps, and the current position (a step, the review screen, or done). After each step it moves to the first visible step that is not completed, so a changed answer that makes a new step apply gets that step asked before review. Answers to steps that no longer apply are dropped by collectAnswers. PromptList gained resume (start at the last field with earlier ones shown as answered) and Esc-to-previous-question, which askAll now also uses. The CLI takes --demo [prompts|wizard]. Guide in docs/wizard.md.

@autoantohaki
autoantohaki merged commit ac4ecb7 into feat/prompts Oct 22, 2026
12 checks passed
autoantohaki added a commit that referenced this pull request Oct 22, 2026
Land the multi-step wizard (#2) and a prompt timing fix on main
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant