From afb443df1ba4bbec025facd8b922fd7cc4e7a04e Mon Sep 17 00:00:00 2001 From: Ilyas Foo Date: Wed, 4 Dec 2024 12:36:43 +0800 Subject: [PATCH] Add Woo rebrand signup page (#96963) * Add feature flag * Update to use css variable colors, add changes for sign up * Rename * Move json * Minor rename --- client/assets/images/icons/Woo_logo_color.svg | 6 + client/blocks/signup-form/index.jsx | 2 +- client/layout/index.jsx | 1 + client/layout/logged-out.jsx | 1 + client/layout/masterbar/woo.jsx | 32 +++- client/layout/masterbar/woo.scss | 139 +++++++++++++++--- config/development.json | 3 +- config/horizon.json | 1 + config/production.json | 3 +- config/stage.json | 3 +- 10 files changed, 157 insertions(+), 34 deletions(-) create mode 100644 client/assets/images/icons/Woo_logo_color.svg diff --git a/client/assets/images/icons/Woo_logo_color.svg b/client/assets/images/icons/Woo_logo_color.svg new file mode 100644 index 00000000000000..428eec450d935c --- /dev/null +++ b/client/assets/images/icons/Woo_logo_color.svg @@ -0,0 +1,6 @@ + diff --git a/client/blocks/signup-form/index.jsx b/client/blocks/signup-form/index.jsx index 053b952f81c8e0..622e91258db11f 100644 --- a/client/blocks/signup-form/index.jsx +++ b/client/blocks/signup-form/index.jsx @@ -1335,7 +1335,7 @@ class SignupForm extends Component { case this.props.isWoo: formProps = { inputPlaceholder: null, - submitButtonLabel: this.props.translate( 'Continue with email' ), + submitButtonLabel: this.props.translate( 'Continue' ), submitButtonLoadingLabel: , }; } diff --git a/client/layout/index.jsx b/client/layout/index.jsx index ac458b1eba632d..2ac273e4d48030 100644 --- a/client/layout/index.jsx +++ b/client/layout/index.jsx @@ -315,6 +315,7 @@ class Layout extends Component { 'feature-flag-woocommerce-core-profiler-passwordless-auth': config.isEnabled( 'woocommerce/core-profiler-passwordless-auth' ), + 'feature-flag-woocommerce-rebrand-2-0': config.isEnabled( 'woocommerce/rebrand-2-0' ), } ); const optionalBodyProps = () => { diff --git a/client/layout/logged-out.jsx b/client/layout/logged-out.jsx index 1f7f42ebc354c1..33e14583e2fb8c 100644 --- a/client/layout/logged-out.jsx +++ b/client/layout/logged-out.jsx @@ -152,6 +152,7 @@ const LayoutLoggedOut = ( { 'feature-flag-woocommerce-core-profiler-passwordless-auth': config.isEnabled( 'woocommerce/core-profiler-passwordless-auth' ), + 'feature-flag-woocommerce-rebrand-2-0': config.isEnabled( 'woocommerce/rebrand-2-0' ), }; let masterbar = null; diff --git a/client/layout/masterbar/woo.jsx b/client/layout/masterbar/woo.jsx index bac1ebe3f09479..0b2cd29cb7e6fa 100644 --- a/client/layout/masterbar/woo.jsx +++ b/client/layout/masterbar/woo.jsx @@ -1,8 +1,10 @@ +import config from '@automattic/calypso-config'; import { Gridicon } from '@automattic/components'; import { Button } from '@wordpress/components'; import { createInterpolateElement, Fragment } from '@wordpress/element'; import { __ } from '@wordpress/i18n'; import { localize } from 'i18n-calypso'; +import WooLogoRebrand2 from 'calypso/assets/images/icons/Woo_logo_color.svg'; import WooLogo from 'calypso/assets/images/icons/woocommerce-logo.svg'; import SVGIcon from 'calypso/components/svg-icon'; import './typekit'; @@ -35,6 +37,27 @@ const WooOauthMasterbar = () => { } } + const isWooRebrand20 = config.isEnabled( 'woocommerce/rebrand-2-0' ); + const logo = isWooRebrand20 ? ( + + ) : ( + + ); + const backNav = (