diff --git a/modules/ppcp-wc-gateway/src/Settings/Fields/pay-later-tab-fields.php b/modules/ppcp-wc-gateway/src/Settings/Fields/pay-later-tab-fields.php
index fab61ca83..f87a7285e 100644
--- a/modules/ppcp-wc-gateway/src/Settings/Fields/pay-later-tab-fields.php
+++ b/modules/ppcp-wc-gateway/src/Settings/Fields/pay-later-tab-fields.php
@@ -25,7 +25,7 @@ return function ( ContainerInterface $container, array $fields ): array {
$settings = $container->get( 'wcgateway.settings' );
assert( $settings instanceof Settings );
- $vault_enabled = $settings->has( 'vault_enabled' ) && $settings->get( 'vault_enabled' );
+ $vault_enabled = false;//$settings->has( 'vault_enabled' ) && $settings->get( 'vault_enabled' );
$pay_later_messaging_enabled_label = $vault_enabled
? __( "You have PayPal vaulting enabled, that's why Pay Later options are unavailable now. You cannot use both features at the same time.", 'woocommerce-paypal-payments' )
@@ -33,11 +33,12 @@ return function ( ContainerInterface $container, array $fields ): array {
$selected_country = $container->get( 'api.shop.country' );
$default_messaging_flex_color = $selected_country === 'US' ? 'white-no-border' : 'white';
-
- $render_preview_element = function ( string $id, string $type ): string {
+ $button_message = __( 'Pay Later Button Preview', 'woocommerce-paypal-payments' );
+ $messaging_message = __( 'Pay Later Messaging Preview', 'woocommerce-paypal-payments' );
+ $render_preview_element = function ( string $id, string $type, string $message ): string {
return '
-
' . __( 'Preview', 'woocommerce-paypal-payments' ) . '
+
' . $message . '
';
};
@@ -82,7 +83,7 @@ return function ( ContainerInterface $container, array $fields ): array {
),
'pay_later_button_preview' => array(
'type' => 'ppcp-text',
- 'text' => $render_preview_element( 'ppcpPayLaterButtonPreview', 'button' ),
+ 'text' => $render_preview_element( 'ppcpPayLaterButtonPreview', 'button', $button_message ),
'screens' => array( State::STATE_ONBOARDED ),
'requirements' => array( 'messages' ),
'gateway' => Settings::PAY_LATER_TAB_ID,
@@ -245,7 +246,7 @@ return function ( ContainerInterface $container, array $fields ): array {
),
'pay_later_general_message_preview' => array(
'type' => 'ppcp-text',
- 'text' => $render_preview_element( 'ppcpGeneralMessagePreview', 'message' ),
+ 'text' => $render_preview_element( 'ppcpGeneralMessagePreview', 'message', $messaging_message ),
'screens' => array( State::STATE_ONBOARDED ),
'requirements' => array( 'messages' ),
'gateway' => Settings::PAY_LATER_TAB_ID,
@@ -369,7 +370,7 @@ return function ( ContainerInterface $container, array $fields ): array {
),
'pay_later_product_message_preview' => array(
'type' => 'ppcp-text',
- 'text' => $render_preview_element( 'ppcpProductMessagePreview', 'message' ),
+ 'text' => $render_preview_element( 'ppcpProductMessagePreview', 'message', $messaging_message ),
'screens' => array( State::STATE_ONBOARDED ),
'requirements' => array( 'messages' ),
'gateway' => Settings::PAY_LATER_TAB_ID,
@@ -493,7 +494,7 @@ return function ( ContainerInterface $container, array $fields ): array {
),
'pay_later_cart_message_preview' => array(
'type' => 'ppcp-text',
- 'text' => $render_preview_element( 'ppcpCartMessagePreview', 'message' ),
+ 'text' => $render_preview_element( 'ppcpCartMessagePreview', 'message', $messaging_message ),
'screens' => array( State::STATE_ONBOARDED ),
'requirements' => array( 'messages' ),
'gateway' => Settings::PAY_LATER_TAB_ID,
@@ -617,7 +618,7 @@ return function ( ContainerInterface $container, array $fields ): array {
),
'pay_later_checkout_message_preview' => array(
'type' => 'ppcp-text',
- 'text' => $render_preview_element( 'ppcpCheckoutMessagePreview', 'message' ),
+ 'text' => $render_preview_element( 'ppcpCheckoutMessagePreview', 'message', $messaging_message ),
'screens' => array( State::STATE_ONBOARDED ),
'requirements' => array( 'messages' ),
'gateway' => Settings::PAY_LATER_TAB_ID,
diff --git a/modules/ppcp-wc-gateway/src/Settings/Fields/paypal-smart-button-fields.php b/modules/ppcp-wc-gateway/src/Settings/Fields/paypal-smart-button-fields.php
index f064b1e7b..82fa1d5f3 100644
--- a/modules/ppcp-wc-gateway/src/Settings/Fields/paypal-smart-button-fields.php
+++ b/modules/ppcp-wc-gateway/src/Settings/Fields/paypal-smart-button-fields.php
@@ -31,7 +31,7 @@ return function ( ContainerInterface $container, array $fields ): array {
$render_preview_element = function ( string $id ): string {
return '
';
};