Changeset 3233853
- Timestamp:
- 02/03/2025 10:33:59 AM (12 months ago)
- Location:
- morkva-flatsome-button-translation
- Files:
-
- 3 added
- 2 edited
-
tags/0.1.1 (added)
-
tags/0.1.1/mrkv-flatsome-button.php (added)
-
tags/0.1.1/readme.txt (added)
-
trunk/mrkv-flatsome-button.php (modified) (2 diffs)
-
trunk/readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
morkva-flatsome-button-translation/trunk/mrkv-flatsome-button.php
r3171805 r3233853 4 4 * Plugin URI: https://morkva.co.ua/ 5 5 * Description: Enables header buttons string translation. Need flatsome customization services? [email protected] 6 * Version: 0.1. 06 * Version: 0.1.1 7 7 * Author: MORKVA 8 8 * Text Domain: morkva-flatsome-button-translation … … 29 29 $btn_text_2 = get_theme_mod( 'header_button_2', 'Button 2' ); 30 30 pll_register_string('flatsome_button2', $btn_text_2, 'flatsome'); 31 $sale_text = get_theme_mod( 'sale_bubble_text', 'Знижка' ); 32 pll_register_string('sale_bubble_text', $sale_text, 'flatsome'); 31 33 } 32 34 } 33 35 add_action('init', 'mrkv_flatsome_button_for_polylang'); 36 37 add_filter('woocommerce_sale_flash', function($html, $post, $product) { 38 if (!get_theme_mod('sale_bubble', 1) || !$product->is_on_sale()) { 39 return $html; 40 } 41 42 $custom_text = pll__( get_theme_mod('sale_bubble_text', 'Sale!') ); 43 $text = $custom_text ? $custom_text : __( 'Sale!', 'woocommerce' ); 44 45 if (get_theme_mod('sale_bubble_percentage')) { 46 $text = flatsome_presentage_bubble($product, $text); 47 } 48 49 $badge_style = get_theme_mod('badge_style', 'default'); 50 51 return '<div class="callout badge badge-' . esc_attr($badge_style) . '"> 52 <div class="badge-inner secondary on-sale"> 53 <span class="onsale">' . esc_html($text) . '</span> 54 </div> 55 </div>'; 56 }, 10, 3); -
morkva-flatsome-button-translation/trunk/readme.txt
r3171805 r3233853 5 5 Tested up to: 6.6 6 6 Requires PHP: 7.4 7 Stable tag: 0.1. 07 Stable tag: 0.1.1 8 8 License: GPLv2 9 9 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 15 15 16 16 Need flatsome customization services? [email protected] 17 18 = 0.1.1 = 19 * [new] додали можливість перекладу Sale bubble
Note: See TracChangeset
for help on using the changeset viewer.