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

Allow for discarding of changes without leaving #9644

Merged
merged 5 commits into from
Nov 9, 2021

Conversation

licitdev
Copy link
Member

@licitdev licitdev commented Nov 9, 2021

Closes #9642.

discard-changes

It is implemented alongside save-options so that there is no need to prompt for confirmation, same as save as copy etc.

@rijkvanzanten
Copy link
Member

I'm wondering about the 80/20 of this. Is navigating away to cancel out of editing the item too cumbersome? Also a little curious if there's a UX problem with two very opposite actions so close together ("save" vs "undo everything"). Thoughts @benhaynes?

@benhaynes
Copy link
Sponsor Member

I don't mind having the explicit option to leave without saving... so there's a very clear option for that. Still, it's the same number of clicks for this versus hitting "back" and "confirm". :)

@licitdev
Copy link
Member Author

licitdev commented Nov 9, 2021

I'm wondering about the 80/20 of this. Is navigating away to cancel out of editing the item too cumbersome?

I added it as I've been debugging the form side of things. Often, making changes to a field and the only way to get the original value back was to click back, confirm, then re-enter. That's 3 clicks in total, with delays due to reloading of data required...

Also a little curious if there's a UX problem with two very opposite actions so close together ("save" vs "undo everything").

Indeed, they are opposite. Will it be better if a divider is added before the discard changes option?

@rijkvanzanten rijkvanzanten added this to the v9.0.1 milestone Nov 9, 2021
@rijkvanzanten rijkvanzanten merged commit 14a5347 into directus:main Nov 9, 2021
@benhaynes
Copy link
Sponsor Member

Happy with or without a divider. It's already clear, bt we could also say: Discard All Changes

@licitdev licitdev deleted the feat/discard-and-stay branch November 9, 2021 19:01
@licitdev licitdev mentioned this pull request Nov 10, 2021
rijkvanzanten pushed a commit that referenced this pull request Dec 1, 2021
* Allow for discarding of changes without leaving

* Update to use v-if for consistency

* Fix boolean logic

* Allow disabling of options

* Remove unused disabled prop
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 4, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Allow discarding of changes without leaving page
4 participants