Skip to content

Commit

Permalink
Update sandbox to test mode copy (#10163)
Browse files Browse the repository at this point in the history
  • Loading branch information
vladolaru authored Jan 16, 2025
1 parent efe1065 commit dbd3b8f
Show file tree
Hide file tree
Showing 5 changed files with 33 additions and 14 deletions.
5 changes: 5 additions & 0 deletions changelog/update-10116-sandbox-to-test-mode-copy
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
Significance: patch
Type: update
Comment: Update the reset account copy for test mode onboarded accounts.


2 changes: 1 addition & 1 deletion client/components/account-status/account-tools/strings.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ export default {
title: __( 'Account Tools', 'woocommerce-payments' ),
description: isInTestModeOnboarding()
? __(
'Your account is in sandbox mode. If you are experiencing problems completing account setup, or wish to test with a different email/country associated with your account, you can reset your account and start from the beginning.',
'You are using a test account. If you are experiencing problems completing account setup, or wish to test with a different email/country associated with your account, you can reset your account and start from the beginning.',
'woocommerce-payments'
)
: __(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,10 @@ const SandboxModeSwitchToLiveNotice: React.FC< Props > = ( {
<>
{ interpolateComponents( {
mixedString: sprintf(
/* translators: %1$s: WooPayments */
/* translators: 1: WooPayments */
__(
// eslint-disable-next-line max-len
'Sandbox mode gives you access to all %1$s features while checkout transactions are simulated. {{learnMoreLink}}Learn more{{/learnMoreLink}}',
'A test account gives you access to all %1$s features while checkout transactions are simulated. {{learnMoreLink}}Learn more{{/learnMoreLink}}',
'woocommerce-payments'
),
'WooPayments'
Expand Down
22 changes: 15 additions & 7 deletions client/overview/modal/reset-account/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import { Button, CardDivider, Modal } from '@wordpress/components';
*/
import './style.scss';
import strings from './strings';
import { isInTestModeOnboarding } from 'utils';

interface Props {
isVisible: boolean;
Expand All @@ -34,13 +35,20 @@ const ResetAccountModal: React.FC< Props > = ( props: Props ) => {
{ strings.description }
</p>
<div className="wcpay-reset-account-modal__content">
<b>{ strings.beforeContinue }</b>
<ol>
<li>{ strings.step1 }</li>
<li>{ strings.step2 }</li>
<li>{ strings.step3 }</li>
</ol>
<CardDivider />
{
// Only show the steps involved info if the account has been onboarded in live mode.
! isInTestModeOnboarding && (
<>
<b>{ strings.beforeContinue }</b>
<ol>
<li>{ strings.step1 }</li>
<li>{ strings.step2 }</li>
<li>{ strings.step3 }</li>
</ol>
<CardDivider />
</>
)
}
<b>{ strings.confirmation }</b>
</div>
<div className="wcpay-reset-account-modal__footer">
Expand Down
14 changes: 10 additions & 4 deletions client/overview/modal/reset-account/strings.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,17 @@ import { __, sprintf } from '@wordpress/i18n';
import { isInTestModeOnboarding } from 'utils';

export default {
title: __( 'Reset account', 'woocommerce-payments' ),
title: isInTestModeOnboarding()
? __( 'Reset your test account', 'woocommerce-payments' )
: __( 'Reset account', 'woocommerce-payments' ),
description: isInTestModeOnboarding()
? __(
'In sandbox mode, you can reset your account and onboard again at any time. Please note that all current WooPayments account details, test transactions, and payouts history will be lost.',
'woocommerce-payments'
? sprintf(
/* translators: 1: WooPayments. */
__(
'When you reset your test account, all data — including your %1$s account details, test transactions, and payouts history — will be lost. This action cannot be undone, but you can create a new test account at any time.',
'woocommerce-payments'
),
'WooPayments'
)
: __(
'If you are experiencing problems completing account setup, or need to change the email/country associated with your account, you can reset your account and start from the beginning.',
Expand Down

0 comments on commit dbd3b8f

Please sign in to comment.