From d7682504d95f982a9b40ddaa1362ebf1778e3fea Mon Sep 17 00:00:00 2001
From: RJ <27843274+rjchow@users.noreply.github.com>
Date: Tue, 20 Aug 2024 17:13:17 +0800
Subject: [PATCH] fix: replaced apostrophes for WooCommerce Admin JS strings in
Homescreen & Core Profiler (#50776)
---
.../client/core-profiler/pages/BusinessInfo.tsx | 8 ++++----
.../core-profiler/pages/BusinessLocation.tsx | 2 +-
.../client/core-profiler/pages/IntroOptIn.tsx | 2 +-
.../client/core-profiler/pages/UserProfile.tsx | 12 ++++++------
.../pages/tests/business-info.test.tsx | 2 +-
.../pages/tests/user-profile.test.tsx | 4 ++--
.../core-profiler/utils/get-loader-stage-meta.tsx | 4 ++--
.../client/dashboard/components/cart-modal.js | 4 ++--
.../client/error-boundary/index.tsx | 2 +-
.../client/guided-tours/shipping-tour.tsx | 14 +++++++-------
.../homescreen/activity-panel/orders/index.js | 2 +-
.../woocommerce-admin/client/homescreen/layout.js | 2 +-
.../components/useSendMagicLink.tsx | 6 +++---
.../woocommerce-admin/client/inbox-panel/index.js | 2 +-
.../pages/launch-store-success/WhatsNext.tsx | 4 ++--
.../pages/launch-store-success/index.tsx | 4 ++--
.../settings/components/confirmation-modal.jsx | 2 +-
.../client/launch-your-store/tour/index.tsx | 4 ++--
.../components/Setup/Configure.js | 2 +-
.../load-sample-product-confirm-modal.tsx | 2 +-
.../fills/import-products/test/index.tsx | 2 +-
.../task-lists/fills/products/test/index.tsx | 2 +-
.../client/task-lists/fills/shipping/index.js | 2 +-
.../task-lists/fills/tax/components/partners.tsx | 2 +-
.../client/task-lists/fills/tax/index.tsx | 2 +-
.../progress-title/default-progress-title.tsx | 6 +++---
.../test/default-progress-title.test.tsx | 12 ++++++------
.../task-lists/reminder-bar/reminder-bar.tsx | 2 +-
.../components/task-headers/launch-your-store.tsx | 2 +-
.../components/task-headers/store-details.js | 2 +-
.../task-headers/woocommerce-payments.js | 2 +-
.../components/task-list-completed-header.tsx | 2 +-
.../components/task-list-completed.tsx | 2 +-
.../onboarding-homepage-notice/index.js | 2 +-
.../onboarding-tax-notice/index.js | 2 +-
plugins/woocommerce-admin/package.json | 2 +-
plugins/woocommerce/changelog/fix-apostrophes | 4 ++++
.../tests/activate-and-setup/core-profiler.spec.js | 10 +++++-----
38 files changed, 74 insertions(+), 70 deletions(-)
create mode 100644 plugins/woocommerce/changelog/fix-apostrophes
diff --git a/plugins/woocommerce-admin/client/core-profiler/pages/BusinessInfo.tsx b/plugins/woocommerce-admin/client/core-profiler/pages/BusinessInfo.tsx
index 8a682cee24a..7d28a8e1395 100644
--- a/plugins/woocommerce-admin/client/core-profiler/pages/BusinessInfo.tsx
+++ b/plugins/woocommerce-admin/client/core-profiler/pages/BusinessInfo.tsx
@@ -90,7 +90,7 @@ export const selectIndustryMapping = {
'woocommerce'
),
im_setting_up_a_store_for_a_client: __(
- "Which industry is your client's business in?",
+ 'Which industry is your client’s business in?',
'woocommerce'
),
};
@@ -238,7 +238,7 @@ export const BusinessInfo = ( {
'woocommerce'
) }
subTitle={ __(
- "We'll use this information to help you set up payments, shipping, and taxes, as well as recommending the best theme for your store.",
+ 'We’ll use this information to help you set up payments, shipping, and taxes, as well as recommending the best theme for your store.',
'woocommerce'
) }
/>
@@ -268,7 +268,7 @@ export const BusinessInfo = ( {
/>
{ __(
- "Don't worry — you can always change it later!",
+ 'Don’t worry — you can always change it later!',
'woocommerce'
) }
@@ -390,7 +390,7 @@ export const BusinessInfo = ( {
{ createInterpolateElement(
__(
// translators: first tag is filled with the country name detected by geolocation, second tag is the country name selected by the user
- "It looks like you're located in . Are you sure you want to create a store in ?",
+ 'It looks like you’re located in . Are you sure you want to create a store in ?',
'woocommerce'
),
{
diff --git a/plugins/woocommerce-admin/client/core-profiler/pages/BusinessLocation.tsx b/plugins/woocommerce-admin/client/core-profiler/pages/BusinessLocation.tsx
index 71b7b3676e4..ab0160ddf09 100644
--- a/plugins/woocommerce-admin/client/core-profiler/pages/BusinessLocation.tsx
+++ b/plugins/woocommerce-admin/client/core-profiler/pages/BusinessLocation.tsx
@@ -45,7 +45,7 @@ export const BusinessLocation = ( {
'woocommerce'
) }
subTitle={ __(
- "We'll use this information to help you set up payments, shipping, and taxes.",
+ 'We’ll use this information to help you set up payments, shipping, and taxes.',
'woocommerce'
) }
/>
diff --git a/plugins/woocommerce-admin/client/core-profiler/pages/IntroOptIn.tsx b/plugins/woocommerce-admin/client/core-profiler/pages/IntroOptIn.tsx
index aa795e175c4..e8861744aaa 100644
--- a/plugins/woocommerce-admin/client/core-profiler/pages/IntroOptIn.tsx
+++ b/plugins/woocommerce-admin/client/core-profiler/pages/IntroOptIn.tsx
@@ -45,7 +45,7 @@ export const IntroOptIn = ( {
title={ __( 'Welcome to Woo!', 'woocommerce' ) }
subTitle={ interpolateComponents( {
mixedString: __(
- "It's great to have you here with us! We'll be guiding you through the setup process – first, answer a few questions to tailor your experience.",
+ 'It’s great to have you here with us! We’ll be guiding you through the setup process – first, answer a few questions to tailor your experience.',
'woocommerce'
),
components: {
diff --git a/plugins/woocommerce-admin/client/core-profiler/pages/UserProfile.tsx b/plugins/woocommerce-admin/client/core-profiler/pages/UserProfile.tsx
index 87fd87058d8..b7980c993d4 100644
--- a/plugins/woocommerce-admin/client/core-profiler/pages/UserProfile.tsx
+++ b/plugins/woocommerce-admin/client/core-profiler/pages/UserProfile.tsx
@@ -20,32 +20,32 @@ import { MultipleSelector } from '../components/multiple-selector/multiple-selec
const businessOptions = [
{
- title: __( "I'm just starting my business", 'woocommerce' ),
+ title: __( 'I’m just starting my business', 'woocommerce' ),
value: 'im_just_starting_my_business' as const,
},
{
- title: __( "I'm already selling", 'woocommerce' ),
+ title: __( 'I’m already selling', 'woocommerce' ),
value: 'im_already_selling' as const,
},
{
- title: __( "I'm setting up a store for a client", 'woocommerce' ),
+ title: __( 'I’m setting up a store for a client', 'woocommerce' ),
value: 'im_setting_up_a_store_for_a_client' as const,
},
];
const sellingOnlineOptions = [
{
- label: __( "Yes, I'm selling online", 'woocommerce' ),
+ label: __( 'Yes, I’m selling online', 'woocommerce' ),
value: 'yes_im_selling_online' as const,
key: 'yes_im_selling_online' as const,
},
{
- label: __( "No, I'm selling offline", 'woocommerce' ),
+ label: __( 'No, I’m selling offline', 'woocommerce' ),
value: 'no_im_selling_offline' as const,
key: 'no_im_selling_offline' as const,
},
{
- label: __( "I'm selling both online and offline", 'woocommerce' ),
+ label: __( 'I’m selling both online and offline', 'woocommerce' ),
value: 'im_selling_both_online_and_offline' as const,
key: 'im_selling_both_online_and_offline' as const,
},
diff --git a/plugins/woocommerce-admin/client/core-profiler/pages/tests/business-info.test.tsx b/plugins/woocommerce-admin/client/core-profiler/pages/tests/business-info.test.tsx
index cc00ca11ce8..e5618147188 100644
--- a/plugins/woocommerce-admin/client/core-profiler/pages/tests/business-info.test.tsx
+++ b/plugins/woocommerce-admin/client/core-profiler/pages/tests/business-info.test.tsx
@@ -94,7 +94,7 @@ describe( 'BusinessInfo', () => {
'im_setting_up_a_store_for_a_client';
render( );
expect(
- screen.getByText( /Which industry is your client's business in?/i )
+ screen.getByText( /Which industry is your client’s business in?/i )
).toBeInTheDocument();
} );
diff --git a/plugins/woocommerce-admin/client/core-profiler/pages/tests/user-profile.test.tsx b/plugins/woocommerce-admin/client/core-profiler/pages/tests/user-profile.test.tsx
index b7382b672aa..fe888367891 100644
--- a/plugins/woocommerce-admin/client/core-profiler/pages/tests/user-profile.test.tsx
+++ b/plugins/woocommerce-admin/client/core-profiler/pages/tests/user-profile.test.tsx
@@ -50,7 +50,7 @@ describe( 'UserProfile', () => {
// @ts-ignore
render( );
const radioInput = screen.getByLabelText< HTMLInputElement >(
- "I'm already selling"
+ 'I’m already selling'
); // Replace with the label of your radio button
// Perform the radio button selection
@@ -65,7 +65,7 @@ describe( 'UserProfile', () => {
expect( onlineSellingQuestion ).toBeInTheDocument();
} );
- it( 'should show online selling question when choosing "Yes, I\'m selling online"', () => {
+ it( 'should show online selling question when choosing "Yes, I’m selling online"', () => {
render(
// @ts-ignore
,
paragraphs: [
{
@@ -42,7 +42,7 @@ const LayoutStage = {
};
const DevelopingStage = {
- title: __( "Woo! Let's get your features ready", 'woocommerce' ),
+ title: __( 'Woo! Let’s get your features ready', 'woocommerce' ),
image: ,
paragraphs: [
{
diff --git a/plugins/woocommerce-admin/client/dashboard/components/cart-modal.js b/plugins/woocommerce-admin/client/dashboard/components/cart-modal.js
index 6854fa9e236..05486e5b27e 100644
--- a/plugins/woocommerce-admin/client/dashboard/components/cart-modal.js
+++ b/plugins/woocommerce-admin/client/dashboard/components/cart-modal.js
@@ -137,7 +137,7 @@ class CartModal extends Component {
{ __(
- "You won't have access to this functionality until the extensions have been purchased and installed.",
+ 'You won’t have access to this functionality until the extensions have been purchased and installed.',
'woocommerce'
) }
@@ -148,7 +148,7 @@ class CartModal extends Component {
isBusy={ purchaseLaterButtonBusy }
onClick={ () => this.onClickPurchaseLater() }
>
- { __( "I'll do it later", 'woocommerce' ) }
+ { __( 'I’ll do it later', 'woocommerce' ) }
diff --git a/plugins/woocommerce-admin/client/task-lists/fills/tax/index.tsx b/plugins/woocommerce-admin/client/task-lists/fills/tax/index.tsx
index 23e5952d0ce..c4c95cdb95e 100644
--- a/plugins/woocommerce-admin/client/task-lists/fills/tax/index.tsx
+++ b/plugins/woocommerce-admin/client/task-lists/fills/tax/index.tsx
@@ -122,7 +122,7 @@ export const Tax: React.FC< TaxProps > = ( { onComplete, query, task } ) => {
createNotice(
'success',
__(
- "You're awesome! One less item on your to-do list ✅",
+ 'You’re awesome! One less item on your to-do list ✅',
'woocommerce'
)
);
diff --git a/plugins/woocommerce-admin/client/task-lists/progress-title/default-progress-title.tsx b/plugins/woocommerce-admin/client/task-lists/progress-title/default-progress-title.tsx
index 45c06e34ac1..ca2be82ba3e 100644
--- a/plugins/woocommerce-admin/client/task-lists/progress-title/default-progress-title.tsx
+++ b/plugins/woocommerce-admin/client/task-lists/progress-title/default-progress-title.tsx
@@ -56,12 +56,12 @@ export const DefaultProgressTitle: React.FC< DefaultProgressTitleProps > = ( {
: __( 'Welcome to your store', 'woocommerce' );
}
if ( completedCount <= 3 ) {
- return __( "Let's get you started", 'woocommerce' ) + ' 🚀';
+ return __( 'Let’s get you started', 'woocommerce' ) + ' 🚀';
}
if ( completedCount > 3 && completedCount < 6 ) {
- return __( "You're on the right track", 'woocommerce' );
+ return __( 'You’re on the right track', 'woocommerce' );
}
- return __( "You're almost there", 'woocommerce' );
+ return __( 'You’re almost there', 'woocommerce' );
}, [ completedCount, hasVisitedTasks, tasksCount ] );
if ( loading ) {
diff --git a/plugins/woocommerce-admin/client/task-lists/progress-title/test/default-progress-title.test.tsx b/plugins/woocommerce-admin/client/task-lists/progress-title/test/default-progress-title.test.tsx
index 4dd25686444..4ab493c3d35 100644
--- a/plugins/woocommerce-admin/client/task-lists/progress-title/test/default-progress-title.test.tsx
+++ b/plugins/woocommerce-admin/client/task-lists/progress-title/test/default-progress-title.test.tsx
@@ -49,7 +49,7 @@ describe( 'default-progress-title', () => {
).toBeInTheDocument();
} );
- it( 'should render "Let\'s get you started" when has task visited and task completed count <= 3', () => {
+ it( 'should render "Let’s get you started" when has task visited and task completed count <= 3', () => {
( useSelect as jest.Mock ).mockImplementation( ( fn ) =>
fn( () => ( {
getTaskList: () => ( {
@@ -60,11 +60,11 @@ describe( 'default-progress-title', () => {
);
render( );
expect(
- screen.getByText( "Let's get you started", { exact: false } )
+ screen.getByText( 'Let’s get you started', { exact: false } )
).toBeInTheDocument();
} );
- it( 'should render "You\'re on the right track" when has task visited and task completed count > 3', () => {
+ it( 'should render "You’re on the right track" when has task visited and task completed count > 3', () => {
( useSelect as jest.Mock ).mockImplementation( ( fn ) =>
fn( () => ( {
getTaskList: () => ( {
@@ -81,11 +81,11 @@ describe( 'default-progress-title', () => {
);
render( );
expect(
- screen.getByText( "You're on the right track", { exact: false } )
+ screen.getByText( 'You’re on the right track', { exact: false } )
).toBeInTheDocument();
} );
- it( 'should render "You\'re almost there" when has task visited and task completed count > 5', () => {
+ it( 'should render "You’re almost there" when has task visited and task completed count > 5', () => {
( useSelect as jest.Mock ).mockImplementation( ( fn ) =>
fn( () => ( {
getTaskList: () => ( {
@@ -104,7 +104,7 @@ describe( 'default-progress-title', () => {
);
render( );
expect(
- screen.getByText( "You're almost there", { exact: false } )
+ screen.getByText( 'You’re almost there', { exact: false } )
).toBeInTheDocument();
} );
} );
diff --git a/plugins/woocommerce-admin/client/task-lists/reminder-bar/reminder-bar.tsx b/plugins/woocommerce-admin/client/task-lists/reminder-bar/reminder-bar.tsx
index 1a96b202e3c..64bb0e04d76 100644
--- a/plugins/woocommerce-admin/client/task-lists/reminder-bar/reminder-bar.tsx
+++ b/plugins/woocommerce-admin/client/task-lists/reminder-bar/reminder-bar.tsx
@@ -52,7 +52,7 @@ const ReminderText: React.FC< ReminderTextProps > = ( {
)
: /* translators: 1: remaining tasks count */
__(
- "🚀 You're doing great! {{strongText}}%1$d steps left{{/strongText}} to get your store up and running. {{setupLink}}Continue setup{{/setupLink}}",
+ '🚀 You’re doing great! {{strongText}}%1$d steps left{{/strongText}} to get your store up and running. {{setupLink}}Continue setup{{/setupLink}}',
'woocommerce'
);
diff --git a/plugins/woocommerce-admin/client/task-lists/setup-task-list/components/task-headers/launch-your-store.tsx b/plugins/woocommerce-admin/client/task-lists/setup-task-list/components/task-headers/launch-your-store.tsx
index bbe78e5a4fb..355e0682eb0 100644
--- a/plugins/woocommerce-admin/client/task-lists/setup-task-list/components/task-headers/launch-your-store.tsx
+++ b/plugins/woocommerce-admin/client/task-lists/setup-task-list/components/task-headers/launch-your-store.tsx
@@ -34,7 +34,7 @@ const LaunchYourStoreHeader = ( {
{ __(
- "It's time to celebrate – you're ready to launch your store! Woo! Hit the button to preview your store and make it public.",
+ 'It’s time to celebrate – you’re ready to launch your store! Woo! Hit the button to preview your store and make it public.',
'woocommerce'
) }
{ __(
- "Get your store up and running in no time. Add your store's address to set up shipping, tax and payments faster.",
+ 'Get your store up and running in no time. Add your store’s address to set up shipping, tax and payments faster.',
'woocommerce'
) }