Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ghostery browser intro hub #665

Merged
merged 120 commits into from Jan 29, 2021
Merged
Changes from 1 commit
Commits
Show all changes
120 commits
Select commit Hold shift + click to select a range
0d1136a
Work towards implementing stub of new intro hub
Nov 11, 2020
d295be0
Implement AppView for Ghostery Browser Hub
Nov 11, 2020
2afb600
Progress towards intro hub skeleton
Nov 13, 2020
9163edb
Merge in develop
Nov 29, 2020
3bb394a
Add stubs for the various onboarding views. Add top level onboarding …
Nov 29, 2020
5a9de84
Merge in develop
Dec 1, 2020
f59a5dd
Continued work on fleshing out the ghostery browser hub react app
Dec 2, 2020
078a137
Factor store creation and Redux HOC construction to utility functions
Dec 2, 2020
388f8f8
Factor out and clean up toast and anti suite reducers for the Hubs
Dec 2, 2020
5b957e3
Factor setup lifecycle actions and constants out to shared-hub dir. N…
Dec 3, 2020
382b81e
Move blocking policy reducer to shared-hub
Dec 3, 2020
a51e0ae
GH-2205: Onboarding - Welcome & Get Started (#637)
benstrumeyer Dec 3, 2020
fb7de96
GH-2207: Onboarding - Success Screen (#638)
benstrumeyer Dec 3, 2020
9799389
GH-2206: Onboarding - Step 1 - Create Account (#639)
benstrumeyer Dec 7, 2020
edc434e
GH-2211: Onboarding - Status Bar (#641)
benstrumeyer Dec 7, 2020
fe5ef4a
Work towards connecting and reconciling new intro hub views
Dec 8, 2020
80f0fcf
Connecting intro hub pieces
Dec 9, 2020
b901263
Merge in latest develop
Dec 9, 2020
5ebb12c
Cleaning up new intro hub SCSS
Dec 9, 2020
50bd0c6
Get inline script that branches to the correct hub to run
Dec 9, 2020
cf1ceaa
Update BlockSettingsView and localization messages (#643)
leuryr Dec 10, 2020
d87f5c2
GH-2210: Onboarding - Step 4 - Choose Plan (#640)
benstrumeyer Dec 10, 2020
e901117
Post-PR-merge SCSS imports cleanup
Dec 10, 2020
3e92e7d
Cleanup of index files and debugging in new intro hub
Dec 11, 2020
bfaf1f3
Continue cleanup of Step1 JSX
Dec 11, 2020
11f3a7e
Render hub step progress bar across all views
Dec 11, 2020
077f680
Add StepNavigator component to manage navigation within a step
Dec 11, 2020
4b55efd
Update data structure passed to OnboardingView by the container to ma…
Dec 11, 2020
89edc23
Finish converting index files to use buildReduxHOC
Dec 11, 2020
e2999d2
Merge in latest develop
Dec 16, 2020
7ad2916
Assorted intro hub fixes
Dec 16, 2020
4717269
Use constants for paths
Dec 22, 2020
0500444
Merge in develop
Dec 22, 2020
9552fc4
Cleanup StepProgressBar
Dec 22, 2020
d237448
Add new intro hub css to template
Dec 22, 2020
4d7a47e
Remove unused navigation mechanism
Dec 22, 2020
e0e806c
Removed unused setup lifecycle actions
Dec 23, 2020
3fc6876
Conditionally include the appropriate hub css
Dec 23, 2020
c444764
Clean up welcome view css, fix up button link
Dec 23, 2020
a24d53c
More welcome view cleanup. Make sure progress bar does not show on We…
Dec 23, 2020
38601b9
GH-2220: Onboarding - Telemetry (#650)
benstrumeyer Jan 4, 2021
6dd38b6
Replace search view element
Jan 4, 2021
66e7b5c
Iterate on search view layout
Jan 4, 2021
b35a01c
Option container design on default search select view
Jan 5, 2021
41677bd
Further work on default search view option containers
Jan 5, 2021
6806dad
Add confirmation modal for default search view
Jan 5, 2021
13b9fbe
Message search extension with user choice
Jan 5, 2021
0781671
Fix typo in template. Tidy up status bar
Jan 5, 2021
fa3b348
Implement updating search preference
Jan 5, 2021
a9e9cf2
GH-2218: Browser Onboarding Copy Edits & Tooltips (#652)
benstrumeyer Jan 5, 2021
bcf1a34
There was a coup attempt at The Capitol yesterday
Jan 7, 2021
c05c7cc
GH-2218: 8.5.5 Translations (#654)
benstrumeyer Jan 7, 2021
9100e95
Ghostery Dawn Intro Hub Miscellaneous Fixes (#653)
benstrumeyer Jan 7, 2021
2c72617
Reduce tooltip delay in Block Settings view
Jan 11, 2021
0bf679b
Make entire option box clickable on default search view
Jan 11, 2021
bf548b9
Rough out custom URL selector
Jan 11, 2021
d2e1f9b
Choose Default Search view option container adjustments
Jan 11, 2021
7c15c2f
Make toasts work
Jan 11, 2021
9472e03
Improvements to UX of custom URL input in choose default search view
Jan 11, 2021
c2a7204
Tidy up custom URL input a little more
Jan 11, 2021
0db8f7c
Remove console statement
Jan 12, 2021
e6e4392
GH-2236: Update onboarding branding (#658)
leuryr Jan 12, 2021
8addd79
Remove custom URL input from choose default search view. Style and co…
Jan 13, 2021
a6b43c1
Choose Default Search view modal styling
Jan 14, 2021
153077f
More choose default search view modal styling
Jan 14, 2021
359b7c2
GH-2244: Unit tests for Ghostery Dawn Intro Hub (#657)
benstrumeyer Jan 19, 2021
3630e93
Remove updates and promotions checkbox and dropdown (#659)
benstrumeyer Jan 19, 2021
3e7e2b9
Fix routing bug
wlycdgr Jan 20, 2021
c423fd7
Step Progress Bar Bug (#661)
benstrumeyer Jan 20, 2021
f877791
Update locale string keys to match new Dawn branding
wlycdgr Jan 20, 2021
0a8b70b
Redirect user to new onboarding from background script instead of thr…
wlycdgr Jan 21, 2021
8abda5e
Fixes for Dawn Onboarding toast messages (#660)
leuryr Jan 21, 2021
8044a41
Reenable search selection which had been disabled for testing purposes
wlycdgr Jan 22, 2021
a1118ca
Leet tool character limits and misc fixes (#662)
benstrumeyer Jan 22, 2021
e60eade
Ghostery Dawn Intro Hub Design Fixes (#663)
benstrumeyer Jan 22, 2021
f1ba4f0
Ghostery Dawn Miscellaneous Bug fixes (#664)
benstrumeyer Jan 22, 2021
4627a05
Update and clean up strings
wlycdgr Jan 25, 2021
d4a0c56
Merge branch 'ghostery-browser-intro-hub' of github.com:ghostery/ghos…
wlycdgr Jan 25, 2021
1b02dfe
Add search dropdown strings
wlycdgr Jan 25, 2021
f5e9536
Clean uphub templates and on install hub branching code
wlycdgr Jan 25, 2021
7f9cbf1
Linter updates and fixes
wlycdgr Jan 25, 2021
4206481
Use correct hub branching logic in background
wlycdgr Jan 25, 2021
9da9a53
Merge branch 'develop' into ghostery-browser-intro-hub
wlycdgr Jan 25, 2021
de2e78a
Open correct hub from Help view of panel
wlycdgr Jan 25, 2021
0e25788
Show the appropriate upgrade plan view to user based on their default…
wlycdgr Jan 25, 2021
8053eea
Copy and formatting fixes in the Choose Plan view
wlycdgr Jan 26, 2021
67a9bb3
Fix Startpage search selection confirmation modal copy
wlycdgr Jan 26, 2021
478ea52
Do not show progress bar on Sucess view
wlycdgr Jan 26, 2021
f5d4668
Prevent title text on Success view from wrapping to a new line
wlycdgr Jan 26, 2021
201f955
Implements Start Trial button logic that branches on user login state…
wlycdgr Jan 26, 2021
ba27815
Change StartPage identifier to Startpage
wlycdgr Jan 26, 2021
09ee4de
Modifications to faciliate testing
wlycdgr Jan 26, 2021
6d4d5ca
Update ghostery-common dependency to ^1.2.1
wlycdgr Jan 26, 2021
f7848dc
Update Startpage logo
wlycdgr Jan 26, 2021
f7ce546
Fix prop type mismatch console warnings on Welcome and Choose Plan sc…
wlycdgr Jan 26, 2021
f92160c
GH-2218: Browser Onboarding Copy Edits (#666)
benstrumeyer Jan 26, 2021
172af55
Fix <li> inside <li> console warning on Block Settings screen
wlycdgr Jan 26, 2021
e104fbc
Remove testing modifications for Dawn nightly build
wlycdgr Jan 26, 2021
ddeb7c5
Modifiations for ease of testing
wlycdgr Jan 26, 2021
776751c
Wrap call to search extension in a try catch to facilitate testing in…
wlycdgr Jan 26, 2021
a45ae4f
Make radio button labels clickable in Block Settings view. Factor ans…
wlycdgr Jan 26, 2021
d7fdfce
Minor copy fixes (#668)
leuryr Jan 27, 2021
7d32d5f
Add dropdown for search options (#667)
leuryr Jan 27, 2021
b321605
Guard against race condition in background when picking which hub to …
wlycdgr Jan 27, 2021
7c573de
Establish Dawn Hub naming consistency
wlycdgr Jan 27, 2021
895ac09
Implement other search engine option retrieval via browser.search.get
wlycdgr Jan 27, 2021
a761103
Only show other search options dropdown if there are actually other o…
wlycdgr Jan 27, 2021
5697c1d
Update search dropdown CSS to handle variable height
wlycdgr Jan 27, 2021
391bc6d
Remove search permission from manifest as it is added to Dawn GBE at …
wlycdgr Jan 28, 2021
13b92f5
setup_number ping parameter (#669)
benstrumeyer Jan 29, 2021
de28d6b
Remove comment that is no longer relevant
wlycdgr Jan 29, 2021
25c8483
Fix block settings styling, update Next or Start Trial button label o…
wlycdgr Jan 29, 2021
c5032c8
Filter our StartPage and Ghostery Glow fromother search engines dropdown
wlycdgr Jan 29, 2021
cffcc7a
GH-2248: Update CTA & links to Plus, Premium, and free trial subscrip…
benstrumeyer Jan 29, 2021
b23a933
Fix certain block settings not setting (#672)
leuryr Jan 29, 2021
b4df03c
Restore some clobbered paths in tests in the old Hub
wlycdgr Jan 29, 2021
649200b
Remove unused old-name directory
wlycdgr Jan 29, 2021
58b7b72
Update Block Settings view tests to match new value in the code
wlycdgr Jan 29, 2021
6455d56
Use our logger instead of console.log in ChooseDefaultSearchView
wlycdgr Jan 29, 2021
2199622
Remove hack that forced Dawn hub from background. Add support for ope…
wlycdgr Jan 29, 2021
File filter
Filter file types
Jump to
Jump to file
Failed to load files.

Always

Just for now

GH-2206: Onboarding - Step 1 - Create Account (#639)

* Make form

* Add skip and learn more links

* Set arrow up/down depending on expanded state

* Make FAQ

* Make list responsive

* Adjust padding of FAQContainer to scroll onto nice spot

* Make sure promoString checkbox text does not wrap

* Add privacy policy link

* Make privacy policy link more responsive

* Make BrowserLogInForm and style responsively

* Refactor Create Account form into a component

* Create BrowserCreateAccountFormContainer and add handlers

* Add error handling to legal consent label

* Remove privacy policy link if learn more is not expanded

* Add handlers for log in view and replace strings

* Add handlers for forgot password and throttle it

* Lower throttle time in case user enters a wrong email

* Make updates checkbox work

* Add signed in view

* Change spacing of title and subtitle for small screens

* Update create account design for small screens

* Center skip link on small screens

* Decrease spacing for small sreens on already have account/create account link

* Decrease width of faqDescription items and privacy policy link

* Open privacy policy link in new tab

* Add confirm password functionality

* Update passwords not match string

* Add global email preferences to user object on account creation success

* Hold input fields in place when error messages appear

* Rename components

* Add propTypes

* Update comments

* Remove newline

* Update confirm password string

* Add comments and minor refactors
  • Loading branch information
benstrumeyer committed Dec 7, 2020
commit 97993894a19b5154a18f707826cc786403dfdc91
@@ -1722,6 +1722,9 @@
"hub_create_account_label_password_invalid_length": {
"message": "Use between 8 and 50 characters."
},
"hub_create_account_confirm_password_do_not_match": {
"message": "Your passwords do not match."
},
"hub_create_account_already_have_account": {
"message": "Already have a Ghostery Account?"
},
@@ -1758,6 +1761,66 @@
"ghostery_browser_hub_onboarding_lets_do_this": {
"message": "Let's do this"
},
"ghostery_browser_hub_onboarding_create_a_ghostery_account": {
"message": "Create a Ghostery Account"
},
"ghostery_browser_hub_onboarding_sync_settings": {
"message": "Allows you to sync settings across browsers and devices"
},
"ghostery_browser_hub_onboarding_already_have_account": {
"message": "I already have an account."
},
"ghostery_browser_hub_onboarding_send_me": {
"message": "Send me"
},
"ghostery_browser_hub_onboarding_updates_and_promotions": {
"message": "updates & promotions."
},
"ghostery_browser_hub_onboarding_skip": {
"message": "Skip"
},
"ghostery_browser_hub_onboarding_we_take_your_privacy_very_seriously": {
"message": "We take your privacy very seriously. Learn more"
},
"ghostery_browser_hub_onboarding_private_by_design": {
"message": "Private by design"
},
"ghostery_browser_hub_onboarding_private_by_design_description": {
"message": "Privacy is incredibly important to us at Ghostery and we've taken extra care to design our products that limits the amount of personal information collected."
},
"ghostery_browser_hub_onboarding_why_do_you_need_my_email": {
"message": "Why do you need my email?"
},
"ghostery_browser_hub_onboarding_why_do_you_need_my_email_description": {
"message": "We've found email is the simplest way to create and secure a unique account without sharing your information. It helps sync your custom settings across your devices."
},
"ghostery_browser_hub_onboarding_what_do_you_use_my_email_for": {
"message": "What do you use my email for?"
},
"ghostery_browser_hub_onboarding_what_do_you_use_my_email_for_description": {
"message": "We never share or sell your personal information. Your email address is used for account management, technical support, product-related communications, and some opt-in features."
},
"ghostery_browser_hub_onboarding_how_secure_is_": {
"message": "How secure is"
},
"ghostery_browser_hub_onboarding_how_secure_is_ghostery_description": {
"message": "We never share or sell your personal information. Your email address is used for account management, technical support, product-related communications, and some opt-in features."
},
"ghostery_browser_hub_onboarding_can_i_remove_my_account": {
"message": "Can I remove my account?"
},
"ghostery_browser_hub_onboarding_can_i_remove_my_account_description": {
"message": "We hope you enjoy using Ghostery, but if you do decide to leave we will remove all of your personal information within 90 days from the date of request."
},
"ghostery_browser_hub_onboarding_visit_our_privacy_policy": {
"message": "Visit our Privacy Policy for more information"
},
"ghostery_browser_hub_onboarding_create_an_account": {
"message": "Create an account."
},
"ghostery_browser_hub_onboarding_you_are_signed_in_as": {
"message": "You are signed in as"
},
"ghostery_browser_hub_onboarding_yay_youre_all_set": {
"message": "Yay! You're all set."
},
@@ -2087,6 +2150,9 @@
"password_colon": {
"message": "Password:"
},
"confirm_password_colon": {
"message": "Confirm Password:"
},
"please_enter_a_valid_email": {
"message": "Please enter a valid email."
},
@@ -27,7 +27,8 @@ import {
GET_USER_SETTINGS_SUCCESS,
GET_USER_SETTINGS_FAIL,
GET_USER_SUBSCRIPTION_DATA_FAIL,
GET_USER_SUBSCRIPTION_DATA_SUCCESS
GET_USER_SUBSCRIPTION_DATA_SUCCESS,
ACCOUNT_DATA_EMAIL_PREFERENCES_CHECKBOX_CHANGE
} from './AccountConstants';
import { SET_TOAST } from '../hub/Views/AppView/AppViewConstants';
import { CLEAR_THEME } from '../panel/constants/constants';
@@ -201,3 +202,10 @@ export const resetPassword = email => dispatch => (
});
})
);

export const handleEmailPreferencesCheckboxChange = (name, checked) => dispatch => (
dispatch({
type: ACCOUNT_DATA_EMAIL_PREFERENCES_CHECKBOX_CHANGE,
payload: { name, checked },
})
);
@@ -36,3 +36,6 @@ export const GET_USER_SETTINGS_FAIL = 'GET_USER_SETTINGS_FAIL';
// Update Subscription Data
export const GET_USER_SUBSCRIPTION_DATA_FAIL = 'GET_USER_SUBSCRIPTION_DATA_FAIL';
export const GET_USER_SUBSCRIPTION_DATA_SUCCESS = 'GET_USER_SUBSCRIPTION_DATA_SUCCESS';

// Opt into/out of updates and promotions sendgrid emails
export const ACCOUNT_DATA_EMAIL_PREFERENCES_CHECKBOX_CHANGE = 'ACCOUNT_DATA_EMAIL_PREFERENCES_CHECKBOX_CHANGE';
@@ -20,7 +20,8 @@ import {
GET_USER_SUBSCRIPTION_DATA_FAIL,
GET_USER_SUBSCRIPTION_DATA_SUCCESS,
RESET_PASSWORD_SUCCESS,
RESET_PASSWORD_FAIL
RESET_PASSWORD_FAIL,
ACCOUNT_DATA_EMAIL_PREFERENCES_CHECKBOX_CHANGE
} from './AccountConstants';
import { UPDATE_PANEL_DATA } from '../panel/constants/constants';

@@ -118,6 +119,15 @@ export default (state = initialState, action) => {
resetPasswordError: true
};
}
case ACCOUNT_DATA_EMAIL_PREFERENCES_CHECKBOX_CHANGE: {
const { name, checked } = action.payload;
let emailPreferences;
if (name === 'global') {
emailPreferences = { ...state.user.emailPreferences, ...{ global: checked } };
}
const user = { ...state.user, ...{ emailPreferences } };
return { ...state, ...{ user } };
}

default: return state;
}
@@ -0,0 +1,256 @@
/**
* Browser Create Account Form
*
* Ghostery Browser Extension
* https://www.ghostery.com/
*
* Copyright 2019 Ghostery, Inc. All rights reserved.
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0
*/

import React, { useRef, useState } from 'react';
import PropTypes from 'prop-types';
import ClassNames from 'classnames';
import { NavLink } from 'react-router-dom';
import { ToggleCheckbox } from '../../../shared-components';

const promoString = `${t('ghostery_browser_hub_onboarding_send_me')} Ghostery ${t('ghostery_browser_hub_onboarding_updates_and_promotions')}`;

/**
* A Functional React component for rendering the Browser Create Account View
* @return {JSX} JSX for rendering the Browser Create Account View of the Hub app
* @memberof HubComponents
*/
const Step1_CreateAccountForm = (props) => {
const {
email,
emailError,
confirmEmail,
confirmEmailError,
firstName,
lastName,
password,
passwordInvalidError,
passwordLengthError,
confirmPassword,
confirmPasswordError,
legalConsentChecked,
legalConsentNotCheckedError,
handleLegalConsentCheckboxChange,
isUpdatesChecked,
handleInputChange,
handleUpdatesCheckboxChange,
handleSubmit,
} = props;

const emailInputClassNames = ClassNames('Step1_CreateAccountForm__inputBox', {
error: emailError,
});
const confirmInputClassNames = ClassNames('Step1_CreateAccountForm__inputBox', {
error: confirmEmailError,
});
const passwordInputClassNames = ClassNames('Step1_CreateAccountForm__inputBox', {
error: passwordInvalidError || passwordLengthError,
});
const legalConsentClassNames = ClassNames('Step1_CreateAccountForm__legalConsentCheckedLabel', {
error: legalConsentNotCheckedError
});

return (
<form onSubmit={handleSubmit}>
<div className="Step1_CreateAccountForm--addPaddingTop row align-center-middle">
<div className="columns small-10 medium-5">
<label htmlFor="create-account-email" className="Step1_CreateAccountForm__inputLabel">
{t('email_colon')}
</label>
<input
id="create-account-email"
className={emailInputClassNames}
name="email"
type="text"
value={email}
onChange={handleInputChange}
pattern=".{1,}"
autoComplete="off"
placeholder="example@mail.com"
/>
{emailError && (
<div className="Step1_CreateAccountForm__inputErrorContainer">
<div className="Step1_CreateAccountForm__inputError">
{t('please_enter_a_valid_email')}
</div>
</div>
)}
</div>
<div className="columns small-10 medium-5">
<label htmlFor="create-account-confirmEmail" className="Step1_CreateAccountForm__inputLabel">
{t('confirm_email_colon')}
</label>
<input
id="create-account-confirmEmail"
className={confirmInputClassNames}
name="confirmEmail"
type="text"
value={confirmEmail}
onChange={handleInputChange}
pattern=".{1,}"
autoComplete="off"
/>
{confirmEmailError && (
<div className="Step1_CreateAccountForm__inputErrorContainer">
<div className="Step1_CreateAccountForm__inputError">
{t('your_email_do_not_match')}
</div>
</div>
)}
</div>
</div>
<div className="row align-center-middle">
<div className="columns small-10 medium-5">
<label htmlFor="create-account-firstName" className="Step1_CreateAccountForm__inputLabel">
{t('hub_create_account_label_first_name')}
</label>
<input
id="create-account-firstName"
className="Step1_CreateAccountForm__inputBox"
name="firstName"
type="text"
value={firstName}
onChange={handleInputChange}
pattern=".{1,}"
autoComplete="off"
/>
</div>
<div className="columns small-10 medium-5">
<label htmlFor="create-account-lastName" className="Step1_CreateAccountForm__inputLabel">
{t('hub_create_account_label_email_last_name')}
</label>
<input
id="create-account-lastName"
className="Step1_CreateAccountForm__inputBox"
name="lastName"
type="text"
value={lastName}
onChange={handleInputChange}
pattern=".{1,}"
autoComplete="off"
/>
</div>
</div>
<div className="row align-center-middle">
<div className="columns small-10 medium-5">
<label htmlFor="create-account-password" className="Step1_CreateAccountForm__inputLabel">
{t('password_colon')}
</label>
<input
id="create-account-password"
className={passwordInputClassNames}
name="password"
type="password"
value={password}
onChange={handleInputChange}
pattern=".{1,}"
autoComplete="off"
/>
{passwordInvalidError && (
<div className="Step1_CreateAccountForm__inputErrorContainer">
<div className="Step1_CreateAccountForm__inputError">
{t('hub_create_account_label_password_invalid')}
</div>
</div>
)}
{passwordLengthError && (
<div className="Step1_CreateAccountForm__inputErrorContainer">
<div className="Step1_CreateAccountForm__inputError">
{t('hub_create_account_label_password_invalid_length')}
</div>
</div>
)}
</div>
<div className="columns small-10 medium-5">
<label htmlFor="create-account-password" className="Step1_CreateAccountForm__inputLabel">
{t('confirm_password_colon')}
</label>
<input
id="create-account-password"
className={passwordInputClassNames}
name="confirmPassword"
type="password"
value={confirmPassword}
onChange={handleInputChange}
pattern=".{1,}"
autoComplete="off"
/>
{confirmPasswordError && (
<div className="Step1_CreateAccountForm__inputErrorContainer">
<div className="Step1_CreateAccountForm__inputError">
{t('hub_create_account_confirm_password_do_not_match')}
</div>
</div>
)}
</div>
</div>
<div className="row align-center-middle">
<div className="columns small-10 medium-8">
<div className="Step1_CreateAccountForm__checkboxContainer Step1_CreateAccountForm--marginBottom flex-container">
<ToggleCheckbox
checked={isUpdatesChecked}
className="ToggleCheckbox--flush-left"
onChange={handleUpdatesCheckboxChange}
/>
<span
className="Step1_CreateAccountForm__promoString"
onClick={handleUpdatesCheckboxChange}
dangerouslySetInnerHTML={{ __html: promoString }}
/>
</div>
</div>
<div className="columns small-10 medium-2" />
</div>
<div className="row align-center-middle">
<div className="columns small-10 medium-8">
<div className="Step1_CreateAccountForm__checkboxContainer BrowserCreateAccountForm--marginBottom flex-container">
<ToggleCheckbox
name="globals"
checked={legalConsentChecked}
className="ToggleCheckbox--flush-left"
onChange={handleLegalConsentCheckboxChange}
/>
<span
className={legalConsentClassNames}
onClick={handleLegalConsentCheckboxChange}
dangerouslySetInnerHTML={{ __html: t('create_account_form_legal_consent_checkbox_label') }}
/>
</div>
</div>
<div className="columns small-10 medium-2" />
</div>
<div className="Step1_CreateAccountForm__ctaButtonContainer">
<button type="submit" className="Step1_CreateAccountForm__ctaButton">{t('create_account')}</button>
</div>
</form>
);
};

// PropTypes ensure we pass required props of the correct type
Step1_CreateAccountForm.propTypes = {
email: PropTypes.string.isRequired,
emailError: PropTypes.bool.isRequired,
confirmEmail: PropTypes.string.isRequired,
confirmEmailError: PropTypes.bool.isRequired,
firstName: PropTypes.string.isRequired,
lastName: PropTypes.string.isRequired,
isUpdatesChecked: PropTypes.bool.isRequired,
password: PropTypes.string.isRequired,
confirmPassword: PropTypes.string.isRequired,
passwordInvalidError: PropTypes.bool.isRequired,
passwordLengthError: PropTypes.bool.isRequired,
handleInputChange: PropTypes.func.isRequired,
handleUpdatesCheckboxChange: PropTypes.func.isRequired,
handleSubmit: PropTypes.func.isRequired,
};

export default Step1_CreateAccountForm;
ProTip! Use n and p to navigate between commits in a pull request.