dify icon indicating copy to clipboard operation
dify copied to clipboard

Undo / Redo in Workflow Editor

Open perzeuss opened this issue 10 months ago • 0 comments

Self Checks

  • [X] I have searched for existing issues search for existing issues, including closed ones.
  • [X] I confirm that I am using English to submit this report (我已阅读并同意 Language Policy).
  • [X] Pleas do not modify this template :) and fill in all the required fields.

1. Is this request related to a challenge you're experiencing?

When working in the Workflow Editor, it often happens that I accidentally delete a node. It also happens that I make changes to the workflow and at some point realize that I liked a previous version better. In these situations I have to make extensive adjustments to the workflow, which can be annoying and demotivating.

2. Describe the feature you'd like to see

  • There is an undo button in the ui, which I can click to undo a change in the workflow editor
  • There is a redo button in the ui, which I can click to redo a change in the workflow editor
  • I can also use keyboard shortcuts to undo / redo things:

Keyboard Shortcuts

  • Undo

    • Windows/Linux: Ctrl + Z
    • macOS: Cmd + Z
  • Redo

    • Windows/Linux: Ctrl + Y or Ctrl + Shift + Z
    • macOS: Cmd + Shift + Z or Cmd + Y

3. How will this feature improve your workflow or experience?

An undo/redo feature saves me having to manually adjust the workflow and I don't have to make backups every now and then if I'm not sure whether the current workflow will work that way or not.

4. Additional context or comments

relates to #3548 #3551

I'll implement it as discussed with the dify team, but will need some help testing it.

5. Can you help us with this feature?

  • [X] I am interested in contributing to this feature.

perzeuss avatar Apr 26 '24 21:04 perzeuss