Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Solicit feedback from students, teachers about undo using control-z or command-z #970

Open
liammulh opened this issue Feb 17, 2023 · 3 comments

Comments

@liammulh
Copy link
Member

While testing phetsims/qa#900, I kept thinking it would be nice to be able to go back to the way my circuit was before I made a change.

It seems like this is a common feature of web apps, and something students and teachers might want. Perhaps we could solicit some feedback from students and teachers?

@samreid
Copy link
Member

samreid commented Feb 18, 2023

From a user's perspective, it would be nice to have undo/redo in the sim, including buttons in the UI so it is more accessible. Some considerations:

  • It should be a full undo/redo stack, so you can go back multiple undos.
  • We would need to decide what constitutes an undo-able step. Just topology changes? Closing a switch? Changing a battery voltage? Moving a voltmeter probe?
  • If a vertex was selected, then cut--After redo, would the vertex be selected again?
  • The implementation would complex, but it would be nice if we could leverage the phet-io circuit state to power it, since that already needs to be a well-established and well-tested feature. This is not the first time we wanted phet-io features in a PhET branded sim. (Presuming that Undo could be state-based rather than a stack of Action items).
  • Even if we were able to power it with PhET-iO states, this would be a significant design and implementation undertaking, and it would probably warrant a future iteration priority.

@samreid samreid removed their assignment Feb 18, 2023
@matthew-blackman
Copy link

@samreid @zepumph and I discussed with @arouinfar and agree that this would be a very nice feature, but is outside the scope of the PhET-iO release milestone. We decided to come back to this when we are read to implement save/load in the PhET brand version of the sim as well as via studio.

@samreid proposed simplifying this issue by using PhET-iO states to store/reference the history of the circuit. However, it will likely be more performant to implement this with a stack of user actions, with each action also having an inverse action that is triggered by 'undo'.

@arouinfar
Copy link
Contributor

I agree that this would be a great feature, but it seems best to consider when we are ready to support save/load, #151. Deferring.

@arouinfar arouinfar removed their assignment Mar 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants