palantir/blueprint

[MultistepDialog] Navigation to later steps is allowed via side navigation when `nextButtonProps` disallows it

開放

#4,871 建立於 2021年8月20日

 (0 則留言) (0 個反應) (0 位負責人)TypeScript (2,167 個分叉)batch import
P2Package: coreType: bughelp wanted

倉庫指標

星標
 (20,263 顆星)
PR 合併指標
 (平均合併 43天 10小時) (30 天內合併 27 個 PR)

描述

Environment

  • Package version(s): @blueprintjs/core@3.48.0

Code Sandbox

https://codesandbox.io/s/blueprint-sandbox-multistepdialog-4di0d

Steps to reproduce

(Using the example in the Code Sandbox)

  1. Advance through each step of the <MultistepDialog> to the end.
  2. See how each step must be "valid" before you can progress.
  3. Before submitting, go back to an earlier step via the "Back" buttons or via the side navigation.
  4. Uncheck the checkbox to make the step invalid.
  5. ✅ See that the "Next" button on the step is now disabled (according to nextButtonProps on that step)
  6. ❌ See that you can still navigate to the next step via the side navigation, as it was previously visited.

Actual behavior

image

Expected behavior

image

If the "Next" button of the current <DialogStep> is disabled through the nextButtonProps, I do not expect to be able to navigate further forwards through the steps via the side navigation; even if I have advanced further previously.

貢獻者指南