diff --git a/locales/en.json b/locales/en.json index 81955e6b..40aaf199 100644 --- a/locales/en.json +++ b/locales/en.json @@ -202,23 +202,8 @@ "headingLogin": "Login", "inputPlaceholder": "Start typing...", "linkSupport": "Send an email", - "linkMigrationText": "Migrate Your Profile", "successWelcome": "Successfully connected to account. Welcome!", - "migrationText1": "Circles Garden profile data is being migrated.", - "migrationText2": "Please login and visit the Migrate Your Profile page to confirm your preference", - "migrationText3": "Please visit the Migrate Your Profile page to confirm your preference" - }, - "MigrateYourProfile": { - "title": "Migrate Your Profile", - "body1": "If you accept the migration of your user profile, this will mean that your data will be transferred to the new Circles team (Gnosis Chain).", - "body2": "At the end of the migration period, all the data that is not transferred will be deleted from current databases.", - "body3": "Your wallet, seed phrase, and CRC will not be deleted regardless of your choice and you will still be able to access to your wallet via circles.garden.", - "labelForm": "Do you consent to the migration of your profile data to the new Circles team?", - "option1": "Yes", - "option2": "no", - "buttonSubmit": "Submit", - "confirmationMsg": "You have successfully updated your migration data status", - "errorMsg": "Sorry, there was a problem with saving changes." + "ShortMsgText": "Circles V2 is launching soon. Join our Discord for live updates" }, "MyProfile": { "buttonCreateOrganization": "Create Shared Wallet", @@ -234,7 +219,6 @@ "buttonDoublePeople": "Trust People", "buttonSendCircles": "Send Circles", "buttonOrganization": "Create Shared Wallet", - "buttonMigration": "Migrate Your Profile", "linkAbout": "About", "linkBugReporting": "Report Bugs", "linkFAQ": "FAQ", diff --git a/src/components/Navigation.js b/src/components/Navigation.js index e61394a7..78cb0871 100644 --- a/src/components/Navigation.js +++ b/src/components/Navigation.js @@ -8,7 +8,6 @@ import { generatePath } from 'react-router-dom'; import { ACTIVITIES_PATH, - MIGRATION_PATH, MY_PROFILE_PATH, ORGANIZATION_PATH, SEARCH_PATH, @@ -152,9 +151,6 @@ const NavigationMain = ({ onClick }) => { {translate('Navigation.buttonSettings')} - - {translate('Navigation.buttonMigration')} - ); }; diff --git a/src/components/NavigationFloating.js b/src/components/NavigationFloating.js index aa654b08..9361007f 100644 --- a/src/components/NavigationFloating.js +++ b/src/components/NavigationFloating.js @@ -6,7 +6,6 @@ import { Link } from 'react-router-dom'; import { EDIT_PROFILE_PATH, - MIGRATION_PATH, MY_PROFILE_PATH, ORGANIZATION_MEMBERS_PATH, } from '~/routes'; @@ -188,11 +187,6 @@ export default function NavigationFloating(props) { }} onClose={handleClose} > - - - - - {props.isAddMembersLink && ( diff --git a/src/components/ShortMessage.js b/src/components/ShortMessage.js new file mode 100644 index 00000000..64d2e141 --- /dev/null +++ b/src/components/ShortMessage.js @@ -0,0 +1,34 @@ +import { Box, Typography } from '@mui/material'; +import makeStyles from '@mui/styles/makeStyles'; +import React from 'react'; + +import ExternalLink from '~/components/ExternalLink'; +import translate from '~/services/locale'; +import { DISCORD_URL } from '~/utils/constants'; + +const useStyles = makeStyles(() => ({ + messageContainer: { + marginTop: '10px', + '& p': { + marginBottom: '10px', + }, + textAlign: 'center', + }, +})); + +const ShortMessage = () => { + const classes = useStyles(); + + return ( + + + {translate('Login.ShortMsgText')} + + + {DISCORD_URL} + + + ); +}; + +export default ShortMessage; diff --git a/src/routes.js b/src/routes.js index 0dc6224f..1dda999f 100644 --- a/src/routes.js +++ b/src/routes.js @@ -10,7 +10,6 @@ import DashboardOrganization from '~/views/DashboardOrganization'; import EditProfile from '~/views/EditProfile'; import Error from '~/views/Error'; import Login from '~/views/Login'; -import MigrateYourProfile from '~/views/MigrateYourProfile'; import NotFound from '~/views/NotFound'; import Onboarding from '~/views/Onboarding'; import OnboardingOrganization from '~/views/OnboardingOrganization'; @@ -38,7 +37,6 @@ export const ACTIVITIES_PATH = '/activities'; export const DASHBOARD_PATH = '/'; export const EDIT_PROFILE_PATH = '/edit'; export const LOGIN_PATH = '/welcome/login'; -export const MIGRATION_PATH = '/profile-migrate'; export const ONBOARDING_PATH = '/welcome/onboarding'; export const ORGANIZATION_MEMBERS_ADD_PATH = '/sharedwallet/members/add'; export const ORGANIZATION_MEMBERS_PATH = '/sharedwallet/members'; @@ -266,11 +264,6 @@ const Routes = () => { - diff --git a/src/services/core.js b/src/services/core.js index 9e255513..e8e4f9a5 100644 --- a/src/services/core.js +++ b/src/services/core.js @@ -145,22 +145,6 @@ const user = { safeAddress, }); }, - - updateProfileMigrationConsent: async ( - safeAddress, - profileMigrationConsent, - ) => { - return await requestCore('user', 'updateProfileMigrationConsent', { - safeAddress, - profileMigrationConsent, - }); - }, - - getProfileMigrationConsent: async (safeAddress) => { - return await requestCore('user', 'getProfileMigrationConsent', { - safeAddress, - }); - }, }; const avatar = { diff --git a/src/store/app/actions.js b/src/store/app/actions.js index 6dd43a7c..5535599e 100644 --- a/src/store/app/actions.js +++ b/src/store/app/actions.js @@ -20,7 +20,6 @@ import { initializeTutorials, resetAllTutorials, } from '~/store/tutorial/actions'; -import { initializeUser } from '~/store/user/actions'; import { burnWallet, initializeWallet } from '~/store/wallet/actions'; import { formatErrorMessage } from '~/utils/debug'; @@ -37,9 +36,6 @@ export function initializeApp() { dispatch(showSpinnerOverlay()); - // Check for migration status - dispatch(initializeUser()); - // Initialize and gather important app states (auth etc.) try { await dispatch(initializeTutorials()); diff --git a/src/store/index.js b/src/store/index.js index 1699ef59..0a4c7b1a 100644 --- a/src/store/index.js +++ b/src/store/index.js @@ -7,7 +7,6 @@ import safeReducer from '~/store/safe/reducers'; import tokenReducer from '~/store/token/reducers'; import trustReducer from '~/store/trust/reducers'; import tutorialReducer from '~/store/tutorial/reducers'; -import userReducer from '~/store/user/reducers'; import walletReducer from '~/store/wallet/reducers'; const rootReducer = combineReducers({ @@ -18,7 +17,6 @@ const rootReducer = combineReducers({ token: tokenReducer, trust: trustReducer, tutorial: tutorialReducer, - user: userReducer, wallet: walletReducer, }); diff --git a/src/store/user/actions.js b/src/store/user/actions.js deleted file mode 100644 index c6e15039..00000000 --- a/src/store/user/actions.js +++ /dev/null @@ -1,83 +0,0 @@ -import { Typography } from '@mui/material'; -import React from 'react'; - -import core from '~/services/core'; -import translate from '~/services/locale'; -import notify, { NotificationsTypes } from '~/store/notifications/actions'; -import ActionTypes from '~/store/user/types'; -import logError from '~/utils/debug'; - -export function initializeUser() { - return async (dispatch, getState) => { - const { safe } = getState(); - - if (!safe.currentAccount) { - return; - } - - try { - const migrationStatus = await core.user.getProfileMigrationConsent( - safe.currentAccount, - ); - - dispatch({ - type: ActionTypes.USER_MIGRATION_UPDATE, - meta: { - isMigrationAccepted: - migrationStatus !== null ? migrationStatus : false, - }, - }); - } catch (error) { - logError(error); - } - }; -} - -export function updateUserMigration(isMigrateData) { - return async (dispatch, getState) => { - const { safe } = getState(); - - if (!safe.currentAccount) { - return; - } - - try { - const updateMigration = await core.user.updateProfileMigrationConsent( - safe.currentAccount, - isMigrateData, - ); - - if (updateMigration) { - dispatch({ - type: ActionTypes.USER_MIGRATION_UPDATE, - meta: { - isMigrationAccepted: isMigrateData, - }, - }); - dispatch( - notify({ - text: ( - - {translate('MigrateYourProfile.confirmationMsg')} - - ), - type: NotificationsTypes.SUCCESS, - }), - ); - /* eslint-disable no-console */ - } - } catch (error) { - logError(error); - dispatch( - notify({ - text: ( - - {translate('MigrateYourProfile.errorMsg')} - - ), - type: NotificationsTypes.ERROR, - }), - ); - } - }; -} diff --git a/src/store/user/reducers.js b/src/store/user/reducers.js deleted file mode 100644 index adc8da5a..00000000 --- a/src/store/user/reducers.js +++ /dev/null @@ -1,20 +0,0 @@ -import update from 'immutability-helper'; - -import ActionTypes from '~/store/user/types'; - -const initialState = { - isMigrationAccepted: null, -}; - -const userReducer = (state = initialState, action) => { - switch (action.type) { - case ActionTypes.USER_MIGRATION_UPDATE: - return update(state, { - isMigrationAccepted: { $set: action.meta.isMigrationAccepted }, - }); - default: - return state; - } -}; - -export default userReducer; diff --git a/src/store/user/types.js b/src/store/user/types.js deleted file mode 100644 index de69c24b..00000000 --- a/src/store/user/types.js +++ /dev/null @@ -1,3 +0,0 @@ -import createTypes from 'redux-create-action-types'; - -export default createTypes('USER_MIGRATION_UPDATE'); diff --git a/src/styles/theme.js b/src/styles/theme.js index 5cf151bc..c7905c43 100644 --- a/src/styles/theme.js +++ b/src/styles/theme.js @@ -425,7 +425,7 @@ export default createTheme({ scrollShadow: 30, layer2: 20, layer1: 10, - backgroundCurvedWrapper: -1, // previously 0, changing so migration link is clickable + backgroundCurvedWrapper: -1, // previously 0, changing so short message link in dashboard is clickable }, custom: { colors, diff --git a/src/utils/constants.js b/src/utils/constants.js index d2c11bfc..f1549f73 100644 --- a/src/utils/constants.js +++ b/src/utils/constants.js @@ -6,6 +6,7 @@ export const NEEDED_TRUST_CONNECTIONS = 1; export const ABOUT_URL = 'https://www.aboutcircles.com'; export const BUG_REPORTING_URL = 'mailto:support@aboutcircles.com'; +export const DISCORD_URL = 'https://discord.com/invite/aboutcircles'; export const EMAIL_URL = 'mailto:hello@aboutcircles.com'; export const FACEBOOK_URL = 'https://facebook.com/CirclesUBI'; export const FAQ_URL = 'https://www.aboutcircles.com/faq'; diff --git a/src/views/Dashboard.js b/src/views/Dashboard.js index 8762434a..b9f807a5 100644 --- a/src/views/Dashboard.js +++ b/src/views/Dashboard.js @@ -1,4 +1,4 @@ -import { Box, Container, Grid, IconButton, Typography } from '@mui/material'; +import { Box, Container, Grid, IconButton } from '@mui/material'; import makeStyles from '@mui/styles/makeStyles'; import clsx from 'clsx'; import React, { Fragment, useEffect, useState } from 'react'; @@ -19,6 +19,7 @@ import Header from '~/components/Header'; import LastInteractions from '~/components/LastInteractions'; import Navigation from '~/components/Navigation'; import NavigationFloating from '~/components/NavigationFloating'; +import ShortMessage from '~/components/ShortMessage'; import View from '~/components/View'; import { useUpdateLoop } from '~/hooks/update'; import translate from '~/services/locale'; @@ -83,6 +84,7 @@ const useStyles = makeStyles((theme) => ({ '& p': { marginBottom: '10px', }, + textAlign: 'center', }, })); @@ -117,17 +119,6 @@ const Dashboard = () => { setIsMenuExpanded(false); }; - const env = process.env.BASE_PATH; - const htmlMigrationContent = ( - - ); - return ( @@ -166,18 +157,7 @@ const Dashboard = () => { - - - {translate('Login.migrationText1')} - - - {htmlMigrationContent} - - + ({ }, }, - migrationContainer: { - marginTop: '10px', - '& p': { - marginBottom: '10px', - }, - }, - paperContainer: { boxShadow: 'none', }, @@ -137,7 +131,7 @@ const Login = () => { - + {translate('Login.headingLogin')} @@ -178,14 +172,7 @@ const Login = () => { {translate('Login.linkSupport')} - - - {translate('Login.migrationText1')} - - - {translate('Login.migrationText2')} - - +