fixing texts

This commit is contained in:
2025-05-23 16:52:53 +02:00
parent 1f550637d6
commit 85267dae72
7 changed files with 14 additions and 14 deletions

View File

@@ -18,7 +18,7 @@
return window.wp.element.createElement(
'div',
null,
window.breezSettings?.description || 'Pay with Lightning.'
window.breezSettings?.description || '.'
);
};

View File

@@ -1,10 +1,10 @@
<?php
/**
* Plugin Name: Breez Nodeless Payments for WooCommerce
* Plugin Name: Lightning Payments for WooCommerce
* Plugin URI: https://github.com/breez-nodeless-woocommerce
* Description: Accept Bitcoin payments in your WooCommerce store using Breez Nodeless Sdk.
* Description: Accept Bitcoin via the Lightning Network using the Breez SDK.
* Version: 1.0.0
* Author: Aljaz Ceru
* Author: Breez
* Author URI: https://breez.technology
* Text Domain: breez-woocommerce
* Domain Path: /languages
@@ -539,8 +539,8 @@ function breez_register_blocks_scripts() {
'wcSettings',
[
'breez' => [
'title' => !empty($settings['title']) ? $settings['title'] : 'Breez Nodeless Payments',
'description' => !empty($settings['description']) ? $settings['description'] : 'Pay with Lightning',
'title' => !empty($settings['title']) ? $settings['title'] : 'Pay with Lightning',
'description' => !empty($settings['description']) ? $settings['description'] : '',
'supports' => ['products'],
'showSavedCards' => false,
'canMakePayment' => true,

View File

@@ -57,7 +57,7 @@ class WC_Gateway_Breez extends WC_Payment_Gateway {
$this->icon = apply_filters('woocommerce_breez_icon', '');
$this->has_fields = false;
$this->method_title = __('Lightning Payments', 'breez-woocommerce');
$this->method_description = __('Pay with Lightning', 'breez-woocommerce');
$this->method_description = __('', 'breez-woocommerce');
$this->supports = array(
'products',
'refunds'

View File

@@ -20,14 +20,14 @@ return array(
'title' => __('Title', 'breez-woocommerce'),
'type' => 'text',
'description' => __('This controls the title which the user sees during checkout.', 'breez-woocommerce'),
'default' => __('Lightning Payments', 'breez-woocommerce'),
'default' => __('Pay with Lightning', 'breez-woocommerce'),
'desc_tip' => true,
),
'description' => array(
'title' => __('Description', 'breez-woocommerce'),
'type' => 'textarea',
'description' => __('This controls the description which the user sees during checkout.', 'breez-woocommerce'),
'default' => __('Pay with Lightning', 'breez-woocommerce'),
'default' => __('', 'breez-woocommerce'),
'desc_tip' => true,
),
'instructions' => array(

View File

@@ -9,12 +9,12 @@ const { PaymentMethodLabel, PaymentMethodIcon } = window.wc.blocksComponents ||
const BreezLabel = () => {
return createElement('div', { className: 'wc-block-components-payment-method-label' },
createElement('span', {}, window.wcSettings?.breez?.title || 'Breez Nodeless Payments')
createElement('span', {}, window.wcSettings?.breez?.title || '')
);
};
const BreezComponent = () => {
const description = window.wcSettings?.breez?.description || 'Pay with Lightning';
const description = window.wcSettings?.breez?.description || '';
return createElement('div', { className: 'wc-block-components-payment-method-description' },
decodeEntities(description)
);

View File

@@ -136,8 +136,8 @@ class Breez_Blocks_Support extends Automattic\WooCommerce\Blocks\Payments\Integr
*/
public function get_payment_method_data() {
$data = [
'title' => !empty($this->settings['title']) ? $this->settings['title'] : 'Breez Nodeless Payments',
'description' => !empty($this->settings['description']) ? $this->settings['description'] : 'Pay with Lightning',
'title' => !empty($this->settings['title']) ? $this->settings['title'] : 'Pay with Lightning',
'description' => !empty($this->settings['description']) ? $this->settings['description'] : '',
'supports' => ['products'],
'showSavedCards' => false,
'canMakePayment' => true,

View File

@@ -37,7 +37,7 @@ class Breez_Unit_Test_Case extends WP_UnitTestCase {
update_option('woocommerce_breez_settings', [
'enabled' => 'yes',
'title' => 'Breez Nodeless Payments',
'description' => 'Pay with Lightning',
'description' => '',
'api_url' => 'https://api.test.breez.com',
'api_key' => 'test_api_key',
'webhook_secret' => 'test_webhook_secret',