From bfe3442ebed906e44058f35117e4daf3d07aa039 Mon Sep 17 00:00:00 2001 From: Awais Ansari <79941147+awais-ansari@users.noreply.github.com> Date: Fri, 13 May 2022 15:22:18 +0500 Subject: [PATCH] feat: update the pii sharing flow for live app (#300) --- .../app-settings-modal/AppSettingsModal.jsx | 2 +- src/pages-and-resources/live/Settings.jsx | 200 ++++++++++-------- .../live/Settings.test.jsx | 148 ++++++------- src/pages-and-resources/live/data/api.js | 89 +++++++- src/pages-and-resources/live/data/slice.js | 31 ++- src/pages-and-resources/live/data/thunks.js | 90 ++++---- .../live/factories/mockApiResponses.jsx | 63 +++--- 7 files changed, 357 insertions(+), 266 deletions(-) diff --git a/src/pages-and-resources/app-settings-modal/AppSettingsModal.jsx b/src/pages-and-resources/app-settings-modal/AppSettingsModal.jsx index 710580511..8c89c43fa 100644 --- a/src/pages-and-resources/app-settings-modal/AppSettingsModal.jsx +++ b/src/pages-and-resources/app-settings-modal/AppSettingsModal.jsx @@ -231,7 +231,7 @@ function AppSettingsModal({
- {intl.formatMessage(messages.providerHelperText, { providerName: values.provider })} -
-{intl.formatMessage(messages.formInstructions)}
-- {intl.formatMessage(messages.requestPiiSharingEnable, { provider: values.provider })} -
- )} + {(status === RequestStatus.IN_PROGRESS) ? ( ++ {intl.formatMessage(messages.requestPiiSharingEnable, { provider: values.provider })} +
+ ) : ( + <> + {(values.piiSharingEmail || values.piiSharingUsername) + && ( ++ {intl.formatMessage(messages.providerHelperText, { providerName: values.provider })} +
+ )} +{intl.formatMessage(messages.formInstructions)}
+