Closed Rahuljagwani closed 1 year ago
@pradeeban this can be reviewed.
I have merged. Thanks, @Rahuljagwani.
Can you tell me your intentions for this new button besides "Resetting" the "Empty" action? (also include that in your project proposal).
I have merged. Thanks, @Rahuljagwani.
Can you tell me your intentions for this new button besides "Resetting" the "Empty" action? (also include that in your project proposal).
Basically, "Reset" contains code of rebuilding the graph from start after the workspace is emptied using "Empty" action and also disables "Undo" and "Redo" when workspace is empty. The other approach to solve this issue was to change the "Undo'' action's code and rebuild the graph. But complexities were arising as user may use "Undo" and "Redo" actions after restoring the graph (after emptying it with "Empty" action). Therefore, new button "Reset" just executes the code to restore a particular graph completely and user can even perform "Redo" and "Undo" actions after restoring it. Also there might be some issues arising with this new button but, I will fix them in coming days.
Got it. We may need a different icon for the "Reset" button to distinguish it from the Undo. Perhaps, a double-pointed arrow instead of a single (as in Undo and Redo).
Got it. We may need a different icon for the "Reset" button to distinguish it from the Undo. Perhaps, a double-pointed arrow instead of a single (as in Undo and Redo).
Sure I will be sending a PR changing its icon and solving some issues related with it.
Nice @Rahuljagwani, does this button restores the last empty graph, or does it also depend on the workspace currently opened?
Also, I think the reset
name is quite confusing I think it should be restore
instead, what do you think @pradeeban
Nice @Rahuljagwani, does this button restores the last empty graph, or does it also depend on the workspace currently opened?
Also, I think the
reset
name is quite confusing I think it should berestore
instead, what do you think @pradeeban
Hi @parteekcoder No currently this button does not depend on workspace due to which a lot of possible bugs are there related to it which we can find and solve together. Yes, the name of button can be changed which is trivial but good suggestion. May be @pradeeban can give more appropriate suggestions regarding this.
"Restore" is a better name. Good suggestion. Please change the label, @Rahuljagwani.
To avoid any conflicts and overlapping, a new button "Reset" is added. Test can be performed here: https://rahuljagwani.github.io/concore-editor/