diff --git a/ui/components/app/step-progress-bar/index.scss b/ui/components/app/step-progress-bar/index.scss
index ab23e660b..3971f2c8b 100644
--- a/ui/components/app/step-progress-bar/index.scss
+++ b/ui/components/app/step-progress-bar/index.scss
@@ -3,6 +3,7 @@
display: flex;
justify-content: space-evenly;
width: 500px;
+ margin: 0 auto;
}
ul.two-steps {
diff --git a/ui/helpers/higher-order-components/authenticated/authenticated.component.js b/ui/helpers/higher-order-components/authenticated/authenticated.component.js
index 1fe151047..bd4604750 100644
--- a/ui/helpers/higher-order-components/authenticated/authenticated.component.js
+++ b/ui/helpers/higher-order-components/authenticated/authenticated.component.js
@@ -10,11 +10,6 @@ import {
export default function Authenticated(props) {
const { isUnlocked, completedOnboarding } = props;
switch (true) {
- // For ONBOARDING_V2 dev purposes,
- // Remove when ONBOARDING_V2 dev complete
- case process.env.ONBOARDING_V2 === true:
- return ;
-
case isUnlocked && completedOnboarding:
return ;
case !completedOnboarding:
diff --git a/ui/pages/onboarding-flow/onboarding-flow.js b/ui/pages/onboarding-flow/onboarding-flow.js
index 6f6c78117..78f7d3144 100644
--- a/ui/pages/onboarding-flow/onboarding-flow.js
+++ b/ui/pages/onboarding-flow/onboarding-flow.js
@@ -55,13 +55,6 @@ export default function OnboardingFlow() {
const nextRoute = useSelector(getFirstTimeFlowTypeRoute);
useEffect(() => {
- // For ONBOARDING_V2 dev purposes,
- // Remove when ONBOARDING_V2 dev complete
- if (process.env.ONBOARDING_V2) {
- history.push(ONBOARDING_METAMETRICS);
- return;
- }
-
if (completedOnboarding && seedPhraseBackedUp) {
history.push(DEFAULT_ROUTE);
return;
diff --git a/ui/pages/onboarding-flow/privacy-settings/privacy-settings.js b/ui/pages/onboarding-flow/privacy-settings/privacy-settings.js
index e372e1130..909e43e83 100644
--- a/ui/pages/onboarding-flow/privacy-settings/privacy-settings.js
+++ b/ui/pages/onboarding-flow/privacy-settings/privacy-settings.js
@@ -10,6 +10,7 @@ import {
} from '../../../helpers/constants/design-system';
import { useI18nContext } from '../../../hooks/useI18nContext';
import {
+ setCompletedOnboarding,
setFeatureFlag,
setUsePhishDetect,
setUseTokenDetection,
@@ -33,6 +34,7 @@ export default function PrivacySettings() {
);
dispatch(setUsePhishDetect(usePhishingDetection));
dispatch(setUseTokenDetection(turnOnTokenDetection));
+ dispatch(setCompletedOnboarding());
history.push(ONBOARDING_PIN_EXTENSION_ROUTE);
};
diff --git a/ui/pages/onboarding-flow/privacy-settings/privacy-settings.test.js b/ui/pages/onboarding-flow/privacy-settings/privacy-settings.test.js
index 51c9df987..63d6caf36 100644
--- a/ui/pages/onboarding-flow/privacy-settings/privacy-settings.test.js
+++ b/ui/pages/onboarding-flow/privacy-settings/privacy-settings.test.js
@@ -2,8 +2,10 @@ import React from 'react';
import { fireEvent } from '@testing-library/react';
import configureMockStore from 'redux-mock-store';
import thunk from 'redux-thunk';
-import * as actions from '../../../store/actions';
-import { renderWithProvider } from '../../../../test/jest';
+import {
+ renderWithProvider,
+ setBackgroundConnection,
+} from '../../../../test/jest';
import PrivacySettings from './privacy-settings';
describe('Privacy Settings Onboarding View', () => {
@@ -19,11 +21,15 @@ describe('Privacy Settings Onboarding View', () => {
const setFeatureFlagStub = jest.fn();
const setUsePhishDetectStub = jest.fn();
const setUseTokenDetectionStub = jest.fn();
+ const completeOnboardingStub = jest
+ .fn()
+ .mockImplementation(() => Promise.resolve());
- actions._setBackgroundConnection({
+ setBackgroundConnection({
setFeatureFlag: setFeatureFlagStub,
setUsePhishDetect: setUsePhishDetectStub,
setUseTokenDetection: setUseTokenDetectionStub,
+ completeOnboarding: completeOnboardingStub,
});
it('should update preferences', () => {
diff --git a/ui/pages/onboarding-flow/welcome/welcome.js b/ui/pages/onboarding-flow/welcome/welcome.js
index 2acd7554e..ab5796905 100644
--- a/ui/pages/onboarding-flow/welcome/welcome.js
+++ b/ui/pages/onboarding-flow/welcome/welcome.js
@@ -13,7 +13,7 @@ import {
} from '../../../helpers/constants/design-system';
import { useI18nContext } from '../../../hooks/useI18nContext';
import { setFirstTimeFlowType } from '../../../store/actions';
-import { INITIALIZE_METAMETRICS_OPT_IN_ROUTE } from '../../../helpers/constants/routes';
+import { ONBOARDING_METAMETRICS } from '../../../helpers/constants/routes';
export default function OnboardingWelcome() {
const t = useI18nContext();
@@ -23,12 +23,12 @@ export default function OnboardingWelcome() {
const onCreateClick = () => {
dispatch(setFirstTimeFlowType('create'));
- history.push(INITIALIZE_METAMETRICS_OPT_IN_ROUTE);
+ history.push(ONBOARDING_METAMETRICS);
};
const onImportClick = () => {
dispatch(setFirstTimeFlowType('import'));
- history.push(INITIALIZE_METAMETRICS_OPT_IN_ROUTE);
+ history.push(ONBOARDING_METAMETRICS);
};
return (