mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-09-06 13:44:42 +08:00
♻️ Set default message for SpinnerOverlay
This commit is contained in:
parent
e2f88cdef8
commit
8e4462d1fe
2 changed files with 7 additions and 6 deletions
|
@ -37,11 +37,7 @@ const SettingsApp = () => {
|
||||||
! merchantIsReady ||
|
! merchantIsReady ||
|
||||||
! settingsIsReady
|
! settingsIsReady
|
||||||
) {
|
) {
|
||||||
return (
|
return <SpinnerOverlay />;
|
||||||
<SpinnerOverlay
|
|
||||||
message={ __( 'Loading…', 'woocommerce-paypal-payments' ) }
|
|
||||||
/>
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
if ( isSendOnlyCountry ) {
|
if ( isSendOnlyCountry ) {
|
||||||
return <SendOnlyMessage />;
|
return <SendOnlyMessage />;
|
||||||
|
|
|
@ -1,6 +1,11 @@
|
||||||
|
import { __ } from '@wordpress/i18n';
|
||||||
import { Spinner } from '@wordpress/components';
|
import { Spinner } from '@wordpress/components';
|
||||||
|
|
||||||
const SpinnerOverlay = ( { message = '' } ) => {
|
const SpinnerOverlay = ( { message = null } ) => {
|
||||||
|
if ( null === message ) {
|
||||||
|
message = __( 'Loading…', 'woocommerce-paypal-payments' );
|
||||||
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="ppcp-r-spinner-overlay">
|
<div className="ppcp-r-spinner-overlay">
|
||||||
{ message && (
|
{ message && (
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue