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

Retain user input when JSON parsing fails #16099

Closed
hoorayimhelping opened this issue Dec 3, 2019 · 2 comments · Fixed by #16255
Closed

Retain user input when JSON parsing fails #16099

hoorayimhelping opened this issue Dec 3, 2019 · 2 comments · Fixed by #16255
Assignees
Labels
difficulty/low Resolving this issue should take a day or two. kind/bug

Comments

@hoorayimhelping
Copy link
Contributor

hoorayimhelping commented Dec 3, 2019

The fix for the app crashing when parsing invalid JSON revealed an issue whereby the JSON that was just parsed is removed from the form, but the form remains and empty.

template

Rather than clearing the form, we want to retain user input when JSON parsing fails.

@hoorayimhelping hoorayimhelping added difficulty/low Resolving this issue should take a day or two. kind/bug labels Dec 3, 2019
@TCL735 TCL735 self-assigned this Dec 13, 2019
@TCL735
Copy link
Contributor

TCL735 commented Dec 16, 2019

Additional side effects that should be added:

  • the text area should give an indication that the input is wrong. we can achieve this with ComponentStatus
  • when the user attempts to correct the invalid input, the text area should no longer indicate that the input is wrong, and the notification should be dismissed

@TCL735
Copy link
Contributor

TCL735 commented Dec 16, 2019

Dismissing the notification automatically when the user changes invalid input might not be necessary or desirable. The notification has details which might be useful for the user to reference while editing. An accidental or incomplete edit would dismiss this potentially useful information.

As is, the notification will expire in 10 seconds. So, we'll go with that. The user can also manually dismiss the notification.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
difficulty/low Resolving this issue should take a day or two. kind/bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants