Add button for delete account
This commit is contained in:
parent
8d4455b7ac
commit
1d2b6e3243
|
@ -314,12 +314,15 @@ export default function Sidebar(props: Props) {
|
||||||
style={{ marginTop: '30px' }}
|
style={{ marginTop: '30px' }}
|
||||||
onClick={() =>
|
onClick={() =>
|
||||||
props.setDialogMessage({
|
props.setDialogMessage({
|
||||||
title: `${constants.CONFIRM} ${constants.LOGOUT}`,
|
title: `${constants.DELETE_ACCOUNT}`,
|
||||||
content: constants.LOGOUT_MESSAGE,
|
content: constants.DELETE_MESSAGE(),
|
||||||
staticBackdrop: true,
|
staticBackdrop: true,
|
||||||
proceed: {
|
proceed: {
|
||||||
text: constants.LOGOUT,
|
text: constants.DELETE_ACCOUNT,
|
||||||
action: logoutUser,
|
action: () => {
|
||||||
|
window.location.href =
|
||||||
|
'mailto:account-deletion@ente.io';
|
||||||
|
},
|
||||||
variant: 'danger',
|
variant: 'danger',
|
||||||
},
|
},
|
||||||
close: { text: constants.CANCEL },
|
close: { text: constants.CANCEL },
|
||||||
|
|
|
@ -192,6 +192,18 @@ const englishConstants = {
|
||||||
CANCEL: 'cancel',
|
CANCEL: 'cancel',
|
||||||
LOGOUT: 'logout',
|
LOGOUT: 'logout',
|
||||||
DELETE_ACCOUNT: 'delete account',
|
DELETE_ACCOUNT: 'delete account',
|
||||||
|
DELETE_MESSAGE: () => (
|
||||||
|
<>
|
||||||
|
<p>
|
||||||
|
please send an email to{' '}
|
||||||
|
<a href="mailto:account-deletion@ente.io">
|
||||||
|
account-deletion@ente.io
|
||||||
|
</a>{' '}
|
||||||
|
from your registered email address.{' '}
|
||||||
|
</p>
|
||||||
|
your request will be processed within 72 hours.
|
||||||
|
</>
|
||||||
|
),
|
||||||
LOGOUT_MESSAGE: 'sure you want to logout?',
|
LOGOUT_MESSAGE: 'sure you want to logout?',
|
||||||
CHANGE: 'change',
|
CHANGE: 'change',
|
||||||
CHANGE_EMAIL: 'change email?',
|
CHANGE_EMAIL: 'change email?',
|
||||||
|
|
Loading…
Reference in a new issue