diff --git a/.eslintrc.js b/.eslintrc.js index c0c9d9be6c..7e518c4b88 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -62,6 +62,12 @@ module.exports = { 'testing-library/no-unnecessary-act': 'off', '@typescript-eslint/no-empty-function': 'off', '@typescript-eslint/no-var-requires': 'off', + '@wordpress/i18n-text-domain': [ + 'error', + { + allowedTextDomain: 'woocommerce-gateway-stripe', + }, + ], }, settings: { react: { @@ -82,4 +88,11 @@ module.exports = { '@wordpress/data', ], }, + ignorePatterns: [ + 'build/**', + 'node_modules/**', + 'phpunit-html/**', + 'release/**', + 'vendor/**', + ], }; diff --git a/changelog.txt b/changelog.txt index 02ea88a48d..9822b95021 100644 --- a/changelog.txt +++ b/changelog.txt @@ -5,6 +5,7 @@ * Update - Increases the default font size for the Optimized Checkout payment element to match the rest of the checkout form * Fix - Checks for the subscription payment method (if it is Stripe) when verifying for the payment method detachment * Dev - Implements WooCommerce constants for the tax statuses +* Fix - Ensure all Javascript strings use the correct text domain for translation = 9.8.0 - 2025-08-11 = * Add - Adds the current setting value for the Optimized Checkout to the Stripe System Status Report data diff --git a/client/settings/general-settings-section/payment-method-checkbox.js b/client/settings/general-settings-section/payment-method-checkbox.js index 4fcb6e27c2..5c48ff712a 100644 --- a/client/settings/general-settings-section/payment-method-checkbox.js +++ b/client/settings/general-settings-section/payment-method-checkbox.js @@ -100,7 +100,8 @@ const PaymentMethodCheckbox = ( { { sprintf( /* translators: %s: a payment method name. */ __( - '%s cannot be enabled at checkout. Click to expand.' + '%s cannot be enabled at checkout. Click to expand.', + 'woocommerce-gateway-stripe' ), label ) } diff --git a/client/settings/stripe-account-connected-notice/index.js b/client/settings/stripe-account-connected-notice/index.js index 54273c620b..2856bdd649 100644 --- a/client/settings/stripe-account-connected-notice/index.js +++ b/client/settings/stripe-account-connected-notice/index.js @@ -45,7 +45,7 @@ const StripeAccountConnectedNotice = () => { if ( shouldShowNotice() ) { localStorage.removeItem( LOCAL_STORAGE_KEY ); dispatch( 'core/notices' ).createSuccessNotice( - __( 'Stripe Account Connected', 'woocommerce' ), + __( 'Stripe Account Connected', 'woocommerce-gateway-stripe' ), { id: 'WOOCOMMERCE_STRIPE_ACCOUNT_CONNECTED_NOTICE', actions: [ diff --git a/client/stripe-utils/cash-app-limit-notice-handler.js b/client/stripe-utils/cash-app-limit-notice-handler.js index e2b5cad76d..c0145dde63 100644 --- a/client/stripe-utils/cash-app-limit-notice-handler.js +++ b/client/stripe-utils/cash-app-limit-notice-handler.js @@ -11,7 +11,8 @@ const LIMIT_NOTICE_CLASSNAME = 'wc-block-checkout__payment-method-limit-notice'; export const cashAppLimitNotice = document.createElement( 'div' ); cashAppLimitNotice.classList.add( 'woocommerce-info', LIMIT_NOTICE_CLASSNAME ); cashAppLimitNotice.textContent = __( - 'Please note that, depending on your account and transaction history, Cash App Pay may reject your transaction due to its amount.' + 'Please note that, depending on your account and transaction history, Cash App Pay may reject your transaction due to its amount.', + 'woocommerce-gateway-stripe' ); cashAppLimitNotice.setAttribute( 'data-testid', 'cash-app-limit-notice' ); diff --git a/readme.txt b/readme.txt index 845eaf3c66..0a6a753598 100644 --- a/readme.txt +++ b/readme.txt @@ -115,5 +115,6 @@ If you get stuck, you can ask for help in the [Plugin Forum](https://wordpress.o * Update - Increases the default font size for the Optimized Checkout payment element to match the rest of the checkout form * Fix - Checks for the subscription payment method (if it is Stripe) when verifying for the payment method detachment * Dev - Implements WooCommerce constants for the tax statuses +* Fix - Ensure all Javascript strings use the correct text domain for translation [See changelog for full details across versions](https://raw.githubusercontent.com/woocommerce/woocommerce-gateway-stripe/trunk/changelog.txt).