From 5eead8b7ee0edb3545b9940284252085bbaa0d97 Mon Sep 17 00:00:00 2001
From: okbel
Date: Tue, 1 May 2018 16:32:42 -0300
Subject: [PATCH] Adding AccountDeletionRequestedSign.js
---
.../AccountDeletionRequestedSign.css | 23 ++++++
.../AccountDeletionRequestedSign.js | 26 +++++++
.../components/DeleteMyAccountDialog.js | 2 +
.../components/DeleteMyAccountFinalStep.js | 4 +-
.../components/DeleteMyAccountStep.css | 7 ++
.../components/DeleteMyAccountStep3.js | 72 +++++++++++--------
6 files changed, 101 insertions(+), 33 deletions(-)
create mode 100644 plugins/talk-plugin-auth/client/profile-settings/components/AccountDeletionRequestedSign.css
create mode 100644 plugins/talk-plugin-auth/client/profile-settings/components/AccountDeletionRequestedSign.js
diff --git a/plugins/talk-plugin-auth/client/profile-settings/components/AccountDeletionRequestedSign.css b/plugins/talk-plugin-auth/client/profile-settings/components/AccountDeletionRequestedSign.css
new file mode 100644
index 000000000..413a3852b
--- /dev/null
+++ b/plugins/talk-plugin-auth/client/profile-settings/components/AccountDeletionRequestedSign.css
@@ -0,0 +1,23 @@
+.container {
+ border : solid 1px #F26563;
+ border-radius: 2px;
+ color: #3B4A53;
+}
+
+.button {
+ color: #787D80;
+ border-radius: 2px;
+ background-color: transparent;
+ height: 30px;
+ font-size: 0.9em;
+ line-height: normal;
+
+ &:hover {
+ background-color: #eaeaea;
+ }
+
+ &.secondary {
+ background-color: #787D80;
+ color: white;
+ }
+}
\ No newline at end of file
diff --git a/plugins/talk-plugin-auth/client/profile-settings/components/AccountDeletionRequestedSign.js b/plugins/talk-plugin-auth/client/profile-settings/components/AccountDeletionRequestedSign.js
new file mode 100644
index 000000000..7d1941fa7
--- /dev/null
+++ b/plugins/talk-plugin-auth/client/profile-settings/components/AccountDeletionRequestedSign.js
@@ -0,0 +1,26 @@
+import React from 'react';
+import cn from 'classnames';
+import { Button, Icon } from 'plugin-api/beta/client/components/ui';
+import styles from './AccountDeletionRequestedSign.css';
+
+class AccountDeletionRequestedSign extends React.Component {
+ render() {
+ return (
+
+
+ Account Deletion Requested
+
+
+ A request to delete your account was received on. If you would like to
+ continue leaving comments, replies or reactions, you may cancel your
+ request to delete your account below before
+
+
+ Cancel Account Deletion Request
+
+
+ );
+ }
+}
+
+export default AccountDeletionRequestedSign;
diff --git a/plugins/talk-plugin-auth/client/profile-settings/components/DeleteMyAccountDialog.js b/plugins/talk-plugin-auth/client/profile-settings/components/DeleteMyAccountDialog.js
index 7c7c47d0b..4e3a1aa99 100644
--- a/plugins/talk-plugin-auth/client/profile-settings/components/DeleteMyAccountDialog.js
+++ b/plugins/talk-plugin-auth/client/profile-settings/components/DeleteMyAccountDialog.js
@@ -60,6 +60,7 @@ class DeleteMyAccountDialog extends React.Component {
)}
{step === 4 && }
@@ -70,6 +71,7 @@ class DeleteMyAccountDialog extends React.Component {
DeleteMyAccountDialog.propTypes = {
closeDialog: PropTypes.func.isRequired,
+ requestAccountDeletion: PropTypes.func.isRequired,
};
export default DeleteMyAccountDialog;
diff --git a/plugins/talk-plugin-auth/client/profile-settings/components/DeleteMyAccountFinalStep.js b/plugins/talk-plugin-auth/client/profile-settings/components/DeleteMyAccountFinalStep.js
index 764dae302..ccbbf61fa 100644
--- a/plugins/talk-plugin-auth/client/profile-settings/components/DeleteMyAccountFinalStep.js
+++ b/plugins/talk-plugin-auth/client/profile-settings/components/DeleteMyAccountFinalStep.js
@@ -11,12 +11,12 @@ const DeleteMyAccountFinalStep = props => (
email address associated with your account.
-
+
Your account is scheduled to be deleted at:
-
+
Account Deletion Date and Time
diff --git a/plugins/talk-plugin-auth/client/profile-settings/components/DeleteMyAccountStep.css b/plugins/talk-plugin-auth/client/profile-settings/components/DeleteMyAccountStep.css
index 98b73f376..53d8ecef8 100644
--- a/plugins/talk-plugin-auth/client/profile-settings/components/DeleteMyAccountStep.css
+++ b/plugins/talk-plugin-auth/client/profile-settings/components/DeleteMyAccountStep.css
@@ -106,3 +106,10 @@
.step {
padding-top: 20px;
}
+
+.scheduledDeletion {
+ i.timeIcon {
+ font-size: 1.2em;
+ padding: 4px;
+ }
+}
diff --git a/plugins/talk-plugin-auth/client/profile-settings/components/DeleteMyAccountStep3.js b/plugins/talk-plugin-auth/client/profile-settings/components/DeleteMyAccountStep3.js
index f91ca42c7..54f49f375 100644
--- a/plugins/talk-plugin-auth/client/profile-settings/components/DeleteMyAccountStep3.js
+++ b/plugins/talk-plugin-auth/client/profile-settings/components/DeleteMyAccountStep3.js
@@ -4,40 +4,50 @@ import cn from 'classnames';
import { Button } from 'plugin-api/beta/client/components/ui';
import styles from './DeleteMyAccountStep.css';
-const DeleteMyAccountStep3 = props => (
-
-
- Are you sure you want to delete your account?
-
-
- To confirm you would like to delete your account please type in the
- following phrase into the text box below:
-
-
-
-
- Cancel
-
-
- Delete My Account
-
-
-
-);
+class DeleteMyAccountStep3 extends React.Component {
+ deleteAndContinue = () => {
+ this.props.requestAccountDeletion();
+ this.props.goToNextStep();
+ };
+
+ render() {
+ return (
+
+
+ Are you sure you want to delete your account?
+
+
+ To confirm you would like to delete your account please type in the
+ following phrase into the text box below:
+
+
+
+
+ Cancel
+
+
+ Delete My Account
+
+
+
+ );
+ }
+}
DeleteMyAccountStep3.propTypes = {
goToNextStep: PropTypes.func.isRequired,
+ requestAccountDeletion: PropTypes.func.isRequired,
cancel: PropTypes.func.isRequired,
};