Skip to content

Commit

Permalink
Rename already-wordpress to already-wpcom
Browse files Browse the repository at this point in the history
  • Loading branch information
gabrielcaires committed Sep 30, 2024
1 parent 55e1bc4 commit 6cebceb
Show file tree
Hide file tree
Showing 8 changed files with 28 additions and 28 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ const CheckboxIntents = ( { label, control, value }: CheckboxProps ) => (
render={ ( { field } ) => {
return (
<CheckboxControl
className="site-migration-already-wordpress__form-checkbox-control"
className="site-migration-already-wpcom__form-checkbox-control"
onChange={ ( isChecked ) => {
if ( isChecked ) {
field.onChange( [ ...field.value, value ] );
Expand Down Expand Up @@ -57,7 +57,7 @@ const OtherDetails = ( { label, control, error }: OtherDetailsProps ) => {
rules={ { required: translate( 'Please, provide more details.' ) } }
render={ ( { field } ) => {
return (
<div className="site-migration-already-wordpress__form-textarea-container">
<div className="site-migration-already-wpcom__form-textarea-container">
<FormLabel htmlFor="otherDetails"> { label } </FormLabel>
<FormTextArea
id="otherDetails"
Expand All @@ -66,12 +66,12 @@ const OtherDetails = ( { label, control, error }: OtherDetailsProps ) => {
placeholder={ translate(
'Share any other details that will help us figure out what we need to do next.'
) }
className={ clsx( 'site-migration-already-wordpress__form-textarea', {
'site-migration-already-wordpress__form-textarea--error': error,
className={ clsx( 'site-migration-already-wpcom__form-textarea', {
'site-migration-already-wpcomrm-textarea--error': error,
} ) }
/>
{ error && error.message && (
<p className="site-migration-already-wordpress__form-error">{ error.message }</p>
<p className="site-migration-already-wpcomrror">{ error.message }</p>
) }
</div>
);
Expand Down Expand Up @@ -105,7 +105,7 @@ const Form: FC< FormProps > = ( { onComplete } ) => {

useEffect( () => {
if ( isSuccess ) {
if ( process.env.NODE_ENV !== 'development' ) {
if ( process.env.NODE_ENV !== 'test' ) {
alert( 'Success!' );
}
onComplete();
Expand All @@ -129,19 +129,19 @@ const Form: FC< FormProps > = ( { onComplete } ) => {
const isOtherChecked = intents.includes( 'other' );

return (
<div className="site-migration-already-wordpress__form-container">
<form className="site-migration-already-wordpress__form" onSubmit={ onSubmit }>
<div className="site-migration-already-wordpress__form-content">
<div className="site-migration-already-wordpress__form-title-container">
<div className="site-migration-already-wpcominer">
<form className="site-migration-already-wpcom__form" onSubmit={ onSubmit }>
<div className="site-migration-already-wpcom__form-content">
<div className="site-migration-already-wpcom__form-title-container">
<h4
className={ clsx( 'site-migration-already-wordpress__form-title', {
'site-migration-already-wordpress__form-title--error': errors.intents,
className={ clsx( 'site-migration-already-wpcomitle', {
'site-migration-already-wpcom__form-title--error': errors.intents,
} ) }
>
{ translate( 'What brought you here today?' ) }
</h4>
{ errors.intents && (
<p className="site-migration-already-wordpress__form-error">
<p className="site-migration-already-wpcom__form-error">
{ errors.intents.message }
</p>
) }
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
@import "@wordpress/base-styles/breakpoints";

.site-migration-already-wordpress__form-title--error,
.site-migration-already-wordpress__form-error {
.site-migration-already-wpcomitle--error,
.site-migration-already-wpcom__form-error {
color: var(--color-error);
font-size: 0.875rem;
font-weight: 500;
}

.site-migration-already-wordpress__form-container {
.site-migration-already-wpcom__form-container {
display: flex;
flex-direction: column;
gap: 1rem;
Expand All @@ -16,7 +16,7 @@
}


.site-migration-already-wordpress__form {
.site-migration-already-wpcom__form {
width: 520px;
padding: 0 2.5rem;
display: flex;
Expand All @@ -25,34 +25,34 @@
box-sizing: border-box;
}

.site-migration-already-wordpress__form .components-checkbox-control__label {
.site-migration-already-wpcom__form .components-checkbox-control__label {
font-size: 0.875rem;
font-weight: 400;
}

.site-migration-already-wordpress__form-title-container {
.site-migration-already-wpcom__form-title-container {
display: flex;
flex-direction: row;
gap: 0.25rem;
align-items: center;
margin-bottom: 0.5rem;
}

.site-migration-already-wordpress__form-title {
.site-migration-already-wpcom__form-title {
font-size: 0.875rem;
font-weight: 600;
margin-bottom: 0;

}

.site-migration-already-wordpress__form-textarea-container {
.site-migration-already-wpcom__form-textarea-container {
margin-top: 1.5rem;
}

.site-migration-already-wordpress__form-textarea {
.site-migration-already-wpcom__form-textarea {
width: 100%;
}

.site-migration-already-wordpress__form-textarea--error {
.site-migration-already-wpcom__form-textarea--error {
border-color: var(--color-error);
}
6 changes: 3 additions & 3 deletions client/landing/stepper/declarative-flow/internals/steps.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -291,9 +291,9 @@ export const STEPS = {
asyncComponent: () => import( './steps-repository/site-migration-plugin-install' ),
},

SITE_MIGRATION_ALREADY_WORDPRESS: {
slug: 'already-wordpress',
asyncComponent: () => import( './steps-repository/site-migration-already-wordpress' ),
SITE_MIGRATION_ALREADY_WPCOM: {
slug: 'already-wpcom',
asyncComponent: () => import( './steps-repository/site-migration-already-wpcom' ),
},

PICK_SITE: {
Expand Down
4 changes: 2 additions & 2 deletions client/landing/stepper/declarative-flow/migration/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ const {
SITE_MIGRATION_STARTED,
SITE_MIGRATION_ASSISTED_MIGRATION,
SITE_MIGRATION_CREDENTIALS,
SITE_MIGRATION_ALREADY_WORDPRESS,
SITE_MIGRATION_ALREADY_WPCOM,
} = STEPS;

const steps = [
Expand All @@ -49,7 +49,7 @@ const steps = [
SITE_MIGRATION_STARTED,
SITE_MIGRATION_ASSISTED_MIGRATION,
SITE_MIGRATION_CREDENTIALS,
SITE_MIGRATION_ALREADY_WORDPRESS,
SITE_MIGRATION_ALREADY_WPCOM,
];

const plans: { [ key: string ]: string } = {
Expand Down

0 comments on commit 6cebceb

Please sign in to comment.