Skip to content

Commit

Permalink
Remove migration (#801)
Browse files Browse the repository at this point in the history
* Add Circles V2 info
  • Loading branch information
mikozet authored Dec 17, 2024
1 parent bd858da commit 570106e
Show file tree
Hide file tree
Showing 16 changed files with 44 additions and 341 deletions.
18 changes: 1 addition & 17 deletions locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -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 <a href='{env}/profile-migrate' rel='noopener noreferrer'>Migrate Your Profile</a> 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",
Expand All @@ -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",
Expand Down
4 changes: 0 additions & 4 deletions src/components/Navigation.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import { generatePath } from 'react-router-dom';

import {
ACTIVITIES_PATH,
MIGRATION_PATH,
MY_PROFILE_PATH,
ORGANIZATION_PATH,
SEARCH_PATH,
Expand Down Expand Up @@ -152,9 +151,6 @@ const NavigationMain = ({ onClick }) => {
<NavigationLink to={SETTINGS_PATH} onClick={onClick}>
{translate('Navigation.buttonSettings')}
</NavigationLink>
<NavigationLink to={MIGRATION_PATH} onClick={onClick}>
{translate('Navigation.buttonMigration')}
</NavigationLink>
</Box>
);
};
Expand Down
6 changes: 0 additions & 6 deletions src/components/NavigationFloating.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import { Link } from 'react-router-dom';

import {
EDIT_PROFILE_PATH,
MIGRATION_PATH,
MY_PROFILE_PATH,
ORGANIZATION_MEMBERS_PATH,
} from '~/routes';
Expand Down Expand Up @@ -188,11 +187,6 @@ export default function NavigationFloating(props) {
}}
onClose={handleClose}
>
<MenuItem onClick={handleClose}>
<Link to={MIGRATION_PATH}>
<Button isOutline>{translate('Navigation.buttonMigration')}</Button>
</Link>
</MenuItem>
{props.isAddMembersLink && (
<MenuItem onClick={handleClose}>
<Link to={ORGANIZATION_MEMBERS_PATH}>
Expand Down
34 changes: 34 additions & 0 deletions src/components/ShortMessage.js
Original file line number Diff line number Diff line change
@@ -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 (
<Box className={classes.messageContainer}>
<Typography align="center" variant="body1">
{translate('Login.ShortMsgText')}
</Typography>
<ExternalLink href={DISCORD_URL} variant="body2">
{DISCORD_URL}
</ExternalLink>
</Box>
);
};

export default ShortMessage;
7 changes: 0 additions & 7 deletions src/routes.js
Original file line number Diff line number Diff line change
Expand Up @@ -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';
Expand Down Expand Up @@ -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';
Expand Down Expand Up @@ -266,11 +264,6 @@ const Routes = () => {
<TrustedRoute component={Share} exact path={SHARE_PATH} />
<TrustedRoute component={Profile} exact path={PROFILE_PATH} />
<TrustedRoute component={Activities} exact path={ACTIVITIES_PATH} />
<TrustedRoute
component={MigrateYourProfile}
exact
path={MIGRATION_PATH}
/>
<TrustedRoute component={EditProfile} exact path={EDIT_PROFILE_PATH} />
<TrustedRoute component={QRGenerator} exact path={QR_GENERATOR_PATH} />
<TrustedRoute component={Search} exact path={SEARCH_PATH} />
Expand Down
16 changes: 0 additions & 16 deletions src/services/core.js
Original file line number Diff line number Diff line change
Expand Up @@ -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 = {
Expand Down
4 changes: 0 additions & 4 deletions src/store/app/actions.js
Original file line number Diff line number Diff line change
Expand Up @@ -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';

Expand All @@ -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());
Expand Down
2 changes: 0 additions & 2 deletions src/store/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -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({
Expand All @@ -18,7 +17,6 @@ const rootReducer = combineReducers({
token: tokenReducer,
trust: trustReducer,
tutorial: tutorialReducer,
user: userReducer,
wallet: walletReducer,
});

Expand Down
83 changes: 0 additions & 83 deletions src/store/user/actions.js

This file was deleted.

20 changes: 0 additions & 20 deletions src/store/user/reducers.js

This file was deleted.

3 changes: 0 additions & 3 deletions src/store/user/types.js

This file was deleted.

2 changes: 1 addition & 1 deletion src/styles/theme.js
Original file line number Diff line number Diff line change
Expand Up @@ -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,
Expand Down
1 change: 1 addition & 0 deletions src/utils/constants.js
Original file line number Diff line number Diff line change
Expand Up @@ -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';
Expand Down
28 changes: 4 additions & 24 deletions src/views/Dashboard.js
Original file line number Diff line number Diff line change
@@ -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';
Expand All @@ -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';
Expand Down Expand Up @@ -83,6 +84,7 @@ const useStyles = makeStyles((theme) => ({
'& p': {
marginBottom: '10px',
},
textAlign: 'center',
},
}));

Expand Down Expand Up @@ -117,17 +119,6 @@ const Dashboard = () => {
setIsMenuExpanded(false);
};

const env = process.env.BASE_PATH;
const htmlMigrationContent = (
<span
dangerouslySetInnerHTML={{
__html: translate('Login.migrationText3', {
env,
}),
}}
/>
);

return (
<Fragment>
<BackgroundCurved gradient="turquoise">
Expand Down Expand Up @@ -166,18 +157,7 @@ const Dashboard = () => {
<Box className={classes.balanceContainer}>
<BalanceDisplay />
</Box>
<Box className={classes.migrationContainer}>
<Typography align="center" variant="body1">
{translate('Login.migrationText1')}
</Typography>
<Typography
align="center"
classes={{ root: 'body3_link_gradient' }}
variant="body1"
>
{htmlMigrationContent}
</Typography>
</Box>
<ShortMessage />
<AppNote messageVersion="dashboard" />
<Grid item xs={12}>
<ButtonDouble
Expand Down
Loading

0 comments on commit 570106e

Please sign in to comment.