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
New student deletion flow #23651
New student deletion flow #23651
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.
Looks really good, but I think I found a couple of edge cases.
if (experiments.isEnabled(experiments.ACCOUNT_DELETION_NEW_FLOW)) { | ||
const deleteAccountMountPoint = document.getElementById('delete-account'); | ||
// Replace deleteAccountMountPoint Rails contents with DeleteAccount component. | ||
ReactDOM.render( |
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 think this needs to check if the mount point actually exists - it's possible it won't be rendered if the user doesn't have permission to delete their own account.
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.
you're right! i'll add that check.
@@ -177,16 +177,20 @@ | |||
%span#change-user-type-status | |||
%button.btn#change-user-type-button{disabled: true}= t('signup_form.user_type_button') | |||
|
|||
%hr.danger.account-page-section-break | |||
%h2.danger= t('user.delete') |
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.
Do we no longer show the horizontal rule and header for the Delete Account section in the case where the user cannot delete their own account?
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 catching that! i think i resolved a merge conflict incorrectly. i'll add that back
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.
🎉
New UI flow for student account deletion (spec).
After successfully submitting, the user is logged out and routed to "/".
Examples
When submitted with the wrong password:
On an unexpected error:
Follow-up Work