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
Script Edit Page: Add confirmation dialog when deleting lesson #37649
Conversation
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.
Good catch!
|
||
render() { | ||
const {lessonName, handleClose, lessonPosToRemove} = this.props; | ||
let bodyText = `Are you sure you want to remove the level named "${lessonName}" from the script?`; |
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.
Sorry to nit, but there is a lot at stake if the user sees this warning, soI think this could benefit from a stronger warning message, like:
big warning: "Are you sure you want to permanently delete the lesson named X and all its contents?"
optional smaller text: "This will delete any details within the lesson, such as level progressions and lesson plan markdown. Individual levels will not be deleted."
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.
@davidsbailey how is this?
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.
👍 looks great!
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.
Thanks for jumping on this!
Bethany pointed out during the bug bash that we did not have a confirmation dialog on the delete of a lesson on the script edit page. This adds a dialog to confirm you want to delete the lesson.
Links
Testing story
Added a test for the new dialog.
Reviewer Checklist: