pipes-digital / pipes

Repository for Pipes
https://pipes.digital
GNU Affero General Public License v3.0
248 stars 19 forks source link

Optionally warn about unsaved changes #116

Open anewuser opened 1 year ago

anewuser commented 1 year ago

Some users might appreciate a warning before leaving the editor page with unsaved changes, as in this example:

uBlock Origin

If you decide to implement this, though, please make it optional. Personally, I'd disable it, since I'm used to opening different pipes just to check or copy something. I consciously close editor tabs and expect this to undo any accidental changes.

onli commented 1 year ago

Hm. That it should be disabled makes me think it might not be the right solution for the data loss problem.

Wouldn't this be better: Save the temporary changes in the browser and restore them when going back to the canves, iff it is exactly the same pipe? Probably should be combined with a marker for which changes are not saved yet (something in the block title?).

anewuser commented 1 year ago

Yes, your idea is less intrusive. What about also adding an option to revert all changes that have been done locally to the canvas since the last time the pipe was saved? If you like this idea, maybe you can also move the save and Pipe Output links to the top, since they aren't visible when all block categories are expanded (on resolutions equal or smaller than 1920×1080):

Screenshot Pipes