-
Notifications
You must be signed in to change notification settings - Fork 3.2k
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
Added confirmation dialog when skipping after entering text #3479
Conversation
@@ -48,6 +48,7 @@ | |||
"sign_in": "Sign In", | |||
"sign_out": "Sign Out", | |||
"skip": "Skip", | |||
"skip_confirmation": "Are you sure you want to skip?", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you move this to task.json file?
|
||
const onClick = () => { | ||
if (props.confirmSkip) { | ||
showModal(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also can you only show the modal when the input is not empty?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm already doing that... that's what the confirmSkip flag is for. I'm setting that to true if taskstatus.replyValidity === "VALID" (see TaskControls.tsx), which corresponds to a non-empty reply field.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ah thanks
Adds a dialog asking the user to confirm whether they want to skip a question after they have already entered text to prevent accidentally losing an answer by clicking the wrong button as requested in #2778