diff --git a/client/signup/controller.js b/client/signup/controller.js index ce7e9895e8984..ea16944a32f2f 100644 --- a/client/signup/controller.js +++ b/client/signup/controller.js @@ -6,13 +6,11 @@ import { createElement } from 'react'; import store from 'store'; import { notFound } from 'calypso/controller'; import { recordPageView } from 'calypso/lib/analytics/page-view'; -import { isWooOAuth2Client } from 'calypso/lib/oauth2-clients'; import { login } from 'calypso/lib/paths'; import { sectionify } from 'calypso/lib/route'; import { addQueryArgs } from 'calypso/lib/url'; import flows from 'calypso/signup/config/flows'; import { isUserLoggedIn } from 'calypso/state/current-user/selectors'; -import { getCurrentOAuth2Client } from 'calypso/state/oauth2-clients/ui/selectors'; import { updateDependencies } from 'calypso/state/signup/actions'; import { getSignupDependencyStore } from 'calypso/state/signup/dependency-store/selectors'; import { setCurrentFlowName, setPreviousFlowName } from 'calypso/state/signup/flow/actions'; @@ -24,7 +22,6 @@ import { getSiteId } from 'calypso/state/sites/selectors'; import { setSelectedSiteId } from 'calypso/state/ui/actions'; import { setLayoutFocus } from 'calypso/state/ui/layout-focus/actions'; import { getStepComponent } from './config/step-components'; -import { isReskinnedFlow } from './is-flow'; import SignupComponent from './main'; import { retrieveSignupDestination, @@ -54,14 +51,6 @@ const basePageTitle = 'Signup'; // used for analytics, doesn't require translati let initialContext; let previousFlowName; -const removeWhiteBackground = function () { - if ( ! document ) { - return; - } - - document.body.classList.remove( 'is-white-signup' ); -}; - function setReferrerPolicy() { try { // Remove existing tags with name="referrer" @@ -104,39 +93,11 @@ export const removeP2SignupClassName = function () { export default { redirectTests( context, next ) { - const isLoggedIn = isUserLoggedIn( context.store.getState() ); - const currentFlowName = getFlowName( context.params, isLoggedIn ); - const isWoo = isWooOAuth2Client( getCurrentOAuth2Client( context.store.getState() ) ); - - if ( isReskinnedFlow( currentFlowName ) ) { - next(); - } else if ( isWoo ) { - // Do nothing, Woo flow background should keep white. - next(); - } else if ( - context.pathname.indexOf( 'domain' ) >= 0 || - context.pathname.indexOf( 'plan' ) >= 0 || - context.pathname.indexOf( 'onboarding-registrationless' ) >= 0 || - context.pathname.indexOf( 'wpcc' ) >= 0 || - context.pathname.indexOf( 'launch-only' ) >= 0 || - context.params.flowName === 'account' || - context.params.flowName === 'crowdsignal' || - context.params.flowName === 'clone-site' - ) { - removeWhiteBackground(); - next(); - } else if ( context.pathname.includes( 'p2' ) ) { - addP2SignupClassName(); - removeWhiteBackground(); - next(); - } else if ( context.pathname.includes( 'videopress' ) ) { + if ( context.pathname.includes( 'videopress' ) ) { addVideoPressSignupClassName(); - removeWhiteBackground(); - next(); - } else { - next(); - return; } + + next(); }, redirectWithoutLocaleIfLoggedIn( context, next ) { const userLoggedIn = isUserLoggedIn( context.store.getState() ); diff --git a/client/signup/steps/user/style.scss b/client/signup/steps/user/style.scss index afb3c091ea602..8a5b583e843d0 100644 --- a/client/signup/steps/user/style.scss +++ b/client/signup/steps/user/style.scss @@ -1,4 +1,4 @@ -body.is-section-signup.is-white-signup .signup { +body.is-section-signup.is-white-signup:not(.is-videopress-signup) .signup { .signup-form.is-horizontal { .signup-form__terms-of-service-link, .auth-form__social-buttons-tos, diff --git a/client/signup/style.scss b/client/signup/style.scss index 5cb4f1062a4b1..6caddb12883a0 100644 --- a/client/signup/style.scss +++ b/client/signup/style.scss @@ -242,7 +242,7 @@ body.is-section-signup .layout:not(.dops):not(.is-wccom-oauth-flow) .formatted-h color: var(--color-text-inverted); } - a { + .signup:not(.is-wpcc):not(.is-crowdsignal) a { color: var(--color-neutral-0); text-decoration: underline; @@ -393,7 +393,7 @@ body.is-section-signup .layout:not(.dops):not(.is-wccom-oauth-flow) .formatted-h * Common styles for reskinSignupFlow a/b test */ body.is-section-stepper, -body.is-section-signup.is-white-signup .layout:not(.dops):not(.is-wccom-oauth-flow) { +body.is-section-signup.is-white-signup:not(.is-videopress-signup) .layout:not(.dops):not(.is-wccom-oauth-flow) { $gray-100: #101517; $gray-60: #50575e; $gray-50: #646970; diff --git a/config/_shared.json b/config/_shared.json index e5fad5aa70f46..f4044df8f17e4 100644 --- a/config/_shared.json +++ b/config/_shared.json @@ -203,11 +203,14 @@ "theme_color": "", "theme_color_admin_color_scheme_override": true, "reskinned_flows": [ + "__disabled_onboarding", "account", "business", "business-2y", "business-3y", "business-monthly", + "clone-site", + "crowdsignal", "do-it-for-me", "do-it-for-me-store", "domain", @@ -220,10 +223,12 @@ "hosting", "hosting-start", "import", + "launch-only", "launch-site", "onboarding", "onboarding-affiliate", "onboarding-pm", + "onboarding-registrationless", "onboarding-with-email", "personal", "personal-2y", @@ -235,9 +240,12 @@ "premium-3y", "premium-monthly", "reader", + "rewind-auto-config", + "rewind-setup", "setup-site", "site-content-collection", "site-selected", + "videopress-account", "website-design-services", "with-plugin", "with-theme",