Changeset 3376726
- Timestamp:
- 10/11/2025 04:10:09 PM (6 months ago)
- Location:
- uniqselprotb/trunk
- Files:
-
- 11 edited
-
assets/css/uniqselprotb-admin.css (modified) (2 diffs)
-
assets/css/uniqselprotb.css (modified) (1 diff)
-
assets/js/uniqselprotb-admin.js (modified) (1 diff)
-
includes/constants/class-uniqselprotb-font-awesome-constant.php (modified) (1 diff)
-
includes/constants/class-uniqselprotb-plugin-constant.php (modified) (1 diff)
-
includes/controllers/class-uniqselprotb-admin-controller.php (modified) (3 diffs)
-
includes/controllers/class-uniqselprotb-frontend-controller.php (modified) (4 diffs)
-
includes/views/uniqselprotb-form-settings.php (modified) (2 diffs)
-
includes/views/uniqselprotb-form-style.php (modified) (2 diffs)
-
readme.txt (modified) (3 diffs)
-
uniqselprotb.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
uniqselprotb/trunk/assets/css/uniqselprotb-admin.css
r3357146 r3376726 69 69 } 70 70 71 .form-table-style input {71 .form-table-style input:not([type="checkbox"]) { 72 72 width: 100px; 73 73 } … … 107 107 padding: 10px; 108 108 } 109 110 .container-icon { 111 border: 1px solid #8c8f94; 112 -webkit-border-radius: 5px; 113 -moz-border-radius: 5px; 114 border-radius: 5px; 115 cursor: pointer; 116 display: inline-block; 117 height: 20px; 118 padding: 4px; 119 text-align: center; 120 vertical-align: middle; 121 width: 20px; 122 } 123 124 .modal-icons { 125 display: none; 126 position: fixed; 127 z-index: 1; 128 left: 0; 129 top: 0; 130 width: 100%; 131 height: 100%; 132 overflow: auto; 133 background-color: rgb(0,0,0); 134 background-color: rgba(0,0,0,0.4); 135 } 136 137 .modal-icons .modal-content { 138 background-color: #fefefe; 139 margin: 15% auto; 140 padding: 20px; 141 border: 1px solid #888; 142 width: 50%; 143 } 144 145 .modal-icons .close { 146 color: #aaa; 147 float: right; 148 font-size: 28px; 149 font-weight: bold; 150 } 151 152 .modal-icons .close:hover, 153 .modal-icons .close:focus { 154 color: black; 155 text-decoration: none; 156 cursor: pointer; 157 } 158 159 .modal-icons .icons { 160 margin-top: 50px; 161 } 162 163 .modal-icons .modal-container-icon { 164 border: 1px solid #8c8f94; 165 -webkit-border-radius: 5px; 166 -moz-border-radius: 5px; 167 border-radius: 5px; 168 cursor: pointer; 169 display: inline-block; 170 height: 30px; 171 margin-left: 10px; 172 margin-top: 10px; 173 padding: 4px; 174 text-align: center; 175 vertical-align: middle; 176 width: 30px; 177 } 178 179 .modal-icons .modal-container-icon i { 180 font-size: 24px; 181 } -
uniqselprotb/trunk/assets/css/uniqselprotb.css
r3357146 r3376726 73 73 } 74 74 75 .usps-top-banner.header-usps.sticky { 76 position: sticky; 77 top: 0; 78 z-index: 9999; 79 } 80 81 .logged-in .usps-top-banner.header-usps.sticky { 82 top: 32px; 83 } 84 75 85 @media (max-width: 1024px) { 76 86 .usps-top-banner.header-usps span.usp-item { -
uniqselprotb/trunk/assets/js/uniqselprotb-admin.js
r3357146 r3376726 4 4 * @package UNIQSELPROTB 5 5 */ 6 jQuery(document).ready(function($) { 6 7 7 jQuery( document ).ready( 8 function ( $ ) { 9 $( '.unique-selling-propositions-top-banner-color-field' ).wpColorPicker(); 8 // Initialize color picker 9 $('.unique-selling-propositions-top-banner-color-field').wpColorPicker(); 10 10 11 function showSettingsForm() 12 { 13 $( '#form-settings' ).show(); 14 $( '#form-style' ).hide(); 11 // ------------------------- 12 // FORM TOGGLE FUNCTIONS 13 // ------------------------- 14 15 function showSettingsForm() { 16 $('#form-settings').show(); 17 $('#form-style').hide(); 18 } 19 20 function showStyleForm() { 21 $('#form-settings').hide(); 22 $('#form-style').show(); 23 } 24 25 // ------------------------- 26 // USP ADD / DELETE LOGIC 27 // ------------------------- 28 29 // Add new USP row 30 function applyClickEventOnAddNewUsp() { 31 $('#add-new-usp').on('click', function(e) { 32 e.preventDefault(); 33 34 const countUsps = $('#form-table-settings tr.tr-heading').length; 35 36 // Get the last row pair 37 const $lastRowTrHeading = $('#form-table-settings tr.tr-heading:last'); 38 const $lastRowTrInputs = $('#form-table-settings tr.tr-inputs:last'); 39 40 // Clone rows 41 const $newRowHeading = $lastRowTrHeading.clone(); 42 const $newRowInputs = $lastRowTrInputs.clone(); 43 44 // Update labels and inputs 45 $newRowHeading.find('th:first label') 46 .attr('for', 'uniqselprotb_usp_' + countUsps) 47 .text('USP ' + (countUsps + 1)); 48 49 $newRowHeading.find('th:last label') 50 .attr('for', 'uniqselprotb_usp_icon_' + countUsps); 51 52 $newRowInputs.find('td:first input[type="text"]') 53 .attr('id', 'uniqselprotb_settings_usp_' + countUsps) 54 .attr('name', 'uniqselprotb_settings[usp_' + countUsps + ']') 55 .val(''); 56 57 $newRowInputs.find('td:last .container-icon') 58 .attr('data-index', countUsps); 59 60 $newRowInputs.find('td:last input[type="hidden"]') 61 .attr('id', 'icon-' + countUsps) 62 .attr('name', 'uniqselprotb_settings[usp_icon_' + countUsps + ']'); 63 64 // Append new rows 65 $('#form-table-settings tbody') 66 .append($newRowHeading) 67 .append($newRowInputs); 68 }); 69 } 70 71 // Delete USP row (delegated — works for dynamically added rows) 72 $(document).on('click', '.delete-usp', function() { 73 const uspsCount = $('tr.tr-inputs').length; 74 75 if (uspsCount === 1) { 76 alert('This item cannot be deleted because it is the only unique selling point (USP) left.'); 77 return; 15 78 } 16 79 17 function showStyleForm() 18 { 19 $( '.form-settings' ).hide(); 20 $( '#form-style' ).show(); 80 const $parentRow = $(this).closest('tr.tr-inputs'); 81 const $headingRow = $parentRow.prev('tr.tr-heading'); 82 83 $parentRow.remove(); 84 $headingRow.remove(); 85 86 // Re-index all rows 87 const $trHeadings = $('tr.tr-heading'); 88 const $trInputs = $('tr.tr-inputs'); 89 90 $trHeadings.each(function(index, el) { 91 $(el).find('.th-usp label') 92 .attr('for', 'uniqselprotb_usp_' + index) 93 .text('USP ' + (index + 1)); 94 95 $(el).find('.th-icon label') 96 .attr('for', 'uniqselprotb_usp_icon_' + index); 97 }); 98 99 $trInputs.each(function(index, el) { 100 $(el).find('td input[type="text"]') 101 .attr('id', 'uniqselprotb_settings_usp_' + index) 102 .attr('name', 'uniqselprotb_settings[usp_' + index + ']'); 103 104 $(el).find('td:last .container-icon') 105 .attr('data-index', index); 106 107 $(el).find('td input[type="hidden"]') 108 .attr('id', 'icon-' + index) 109 .attr('name', 'uniqselprotb_settings[usp_icon_' + index + ']'); 110 }); 111 }); 112 113 // ------------------------- 114 // MODAL ICON PICKER 115 // ------------------------- 116 117 let uspIcon = null; 118 let uspIndex = 0; 119 120 // Open modal and store clicked icon reference 121 $(document).on('click', '.container-icon, .container-icon i', function() { 122 const $container = $(this).closest('.container-icon'); 123 uspIcon = $container.children('i').first(); // safer than find() 124 uspIndex = $container.data('index'); 125 126 $('#modal-icons').show(); 127 }); 128 129 // Close modal (bind once) 130 $('#modal-icons .close').on('click', function() { 131 $('#modal-icons').hide(); 132 }); 133 134 // Select icon inside modal 135 $('#modal-icons .icons').on('click.iconHandler', '.modal-container-icon, .modal-container-icon i', function() { 136 if (!uspIcon) return; 137 138 const $container = $(this).closest('.modal-container-icon'); 139 const iconClass = $container.data('icon'); 140 141 // Apply selected icon 142 uspIcon.attr('class', iconClass); 143 144 // Update hidden input value 145 $('#icon-' + uspIndex).val(iconClass); 146 147 // Close modal 148 $('#modal-icons').hide(); 149 }); 150 151 // ------------------------- 152 // TAB SWITCHING 153 // ------------------------- 154 155 $('.nav-tab').on('click', function() { 156 const tabId = $(this).attr('href'); 157 158 if (tabId === '#form-settings') { 159 showSettingsForm(); 160 } else if (tabId === '#form-style') { 161 showStyleForm(); 21 162 } 22 163 23 function applyClickEventOnAddNewUsp() 24 { 25 $( '#add-new-usp' ).on( 26 'click' , 27 function ( e ) { 164 $('.nav-tab').removeClass('nav-tab-active'); 165 $(this).addClass('nav-tab-active'); 28 166 29 e.preventDefault(); 167 return false; 168 }); 30 169 31 const countUsps = $( '#form-table-settings tr.tr-heading' ).length; 170 // ------------------------- 171 // INITIALIZE 172 // ------------------------- 32 173 33 // Get the last .tr-heading row inside tbody. 34 var $lastRowTrHeading = $( '#form-table-settings tr.tr-heading:last' ); 35 var $lastRowTrInputs = $( '#form-table-settings tr.tr-inputs:last' ); 174 showSettingsForm(); 175 applyClickEventOnAddNewUsp(); 36 176 37 // Clone last row. 38 var $newRowHeading = $lastRowTrHeading.clone(); 39 40 var $newRowInputs = $lastRowTrInputs.clone(); 41 42 $newRowHeading.find( 'th:first label' ).attr( 'for', 'uniqselprotb_usp_' + countUsps ).text( 'USP ' + ( countUsps + 1 ) ); 43 $newRowHeading.find( 'th:last label' ).attr( 'for', 'uniqselprotb_usp_icon_' + countUsps ); 44 45 $newRowInputs.find( 'td:first input' ) 46 .attr( 'id', 'uniqselprotb_settings_usp_' + countUsps ) 47 .attr( 'name', 'uniqselprotb_settings[usp_' + countUsps + ']' ) 48 .val( '' ); 49 50 $newRowInputs.find( 'td:last select' ) 51 .attr( 'name', 'uniqselprotb_settings[usp_icon_' + countUsps + ']' ); 52 53 // Append the new row to the table. 54 $( '#form-table-settings tbody' ).append( $newRowHeading ).append( $newRowInputs ); 55 56 applyClickEventOnDeleteUsp(); 57 } 58 ); 59 } 60 61 function applyClickEventOnDeleteUsp() 62 { 63 $( '.delete-usp' ).on( 64 'click' , 65 function ( e ) { 66 const uspsCount = $( 'tr.tr-inputs' ).length; 67 68 if (uspsCount === 1 ) { 69 alert( 'This item cannot be deleted because it is the only unique selling point (USP) left.' ); 70 } else { 71 const parentRow = $( this ).closest( 'tr.tr-inputs' ); 72 const previewRowTrHeading = parentRow.prev( 'tr.tr-heading' ); 73 74 parentRow.remove(); 75 previewRowTrHeading.remove(); 76 77 const trHeadings = $( 'tr.tr-heading' ); 78 const trInputs = $( 'tr.tr-inputs' ); 79 80 $.each( 81 trHeadings, 82 function (index, el) { 83 $( el ).find( '.th-usp label' ) 84 .attr( 'for', 'uniqselprotb_usp_' + (index) ) 85 .text( 'USP ' + (index + 1) ); 86 87 $( el ).find( '.th-icon label' ) 88 .attr( 'for', 'uniqselprotb_usp_icon_' + (index) ); 89 } 90 ); 91 92 $.each( 93 trInputs, 94 function (index, el) { 95 $( el ).find( 'td input[type="text"]' ) 96 .attr( 'id', 'uniqselprotb_settings_usp_' + (index) ) 97 .attr( 'name', 'uniqselprotb_settings[usp_' + index + ']' ); 98 99 $( el ).find( 'td select' ) 100 .attr( 'id', 'icon-' + (index) ) 101 .attr( 'name', 'uniqselprotb_settings[usp_icon_' + index + ']' ); 102 } 103 ); 104 } 105 } 106 ); 107 } 108 109 showSettingsForm(); 110 111 $( '.nav-tab' ).on( 112 'click' , 113 function () { 114 const tabId = $( this ).attr( 'href' ); 115 116 if (tabId === '#form-settings' ) { 117 showSettingsForm() 118 } else if (tabId === '#form-style' ) { 119 showStyleForm(); 120 } 121 122 $( '.nav-tab' ).removeClass( 'nav-tab-active' ); 123 $( this ).addClass( 'nav-tab-active' ); 124 125 return false; 126 } 127 ); 128 129 applyClickEventOnAddNewUsp(); 130 applyClickEventOnDeleteUsp(); 131 132 } 133 ); 177 }); -
uniqselprotb/trunk/includes/constants/class-uniqselprotb-font-awesome-constant.php
r3357146 r3376726 23 23 24 24 const ICONS_LIST = array( 25 'fa-solid fa-truck' => 'Truck',26 'fa-solid fa-envelope' => 'Envelope',27 'fa-solid fa-map-marker-alt' => 'Map Marker',28 'fa-solid fa-phone' => 'Phone',29 'fa-solid fa-box' => 'Box',30 'fa-solid fa-user' => 'User',31 'fa-solid fa-clock' => 'Clock',32 25 'fa-solid fa-calendar' => 'Calendar', 33 'fa-solid fa-store' => 'Store',34 26 'fa-solid fa-shipping-fast' => 'Fast Shipping', 35 'fa-solid fa-globe' => 'Globe',36 27 'fa-solid fa-clipboard-list' => 'Checklist', 37 'fa-solid fa-undo' => 'Returns', 38 'fa-solid fa-check-circle' => 'Check Circle', 28 29 // --- Trust & Security --- 30 'fa-solid fa-lock' => 'Secure Payment', 31 'fa-solid fa-shield-halved' => 'Buyer Protection', 32 'fa-solid fa-certificate' => 'Certified Quality', 33 'fa-solid fa-user-shield' => 'Data Protection', 34 'fa-solid fa-fingerprint' => 'Authentication', 35 'fa-solid fa-check-circle' => 'Verified Quality', 36 37 // --- Shipping & Delivery --- 38 'fa-solid fa-truck' => 'Fast Delivery', 39 'fa-solid fa-truck-fast' => 'Express Shipping', 40 'fa-solid fa-box' => 'Safe Packaging', 41 'fa-solid fa-warehouse' => 'In Stock', 42 'fa-solid fa-globe' => 'Worldwide Shipping', 43 'fa-solid fa-plane' => 'International Delivery', 44 45 // --- Support & Service --- 46 'fa-solid fa-headset' => 'Customer Support', 47 'fa-solid fa-phone' => '24/7 Hotline', 48 'fa-solid fa-envelope' => 'Email Support', 49 'fa-solid fa-comments' => 'Live Chat', 50 'fa-solid fa-user' => 'Personal Service', 51 'fa-solid fa-users' => 'Community Support', 52 53 // --- Return & Guarantee --- 54 'fa-solid fa-rotate-left' => 'Easy Returns', 55 'fa-solid fa-undo' => 'Money-Back Guarantee', 56 57 // --- Price & Savings --- 58 'fa-solid fa-tags' => 'Best Price', 59 'fa-solid fa-percent' => 'Discounts Available', 60 'fa-solid fa-coins' => 'Value for Money', 61 'fa-solid fa-gift' => 'Free Gifts', 62 63 // --- Quality & Materials --- 64 'fa-solid fa-gem' => 'Premium Quality', 65 'fa-solid fa-crown' => 'Top Brand', 66 'fa-solid fa-award' => 'Award Winning', 67 'fa-solid fa-hammer' => 'Durable Materials', 68 69 // --- Sustainability & Ethics --- 70 'fa-solid fa-leaf' => 'Eco Friendly', 71 'fa-solid fa-recycle' => 'Recyclable Packaging', 72 'fa-solid fa-solar-panel' => 'Energy Efficient', 73 'fa-solid fa-hand-holding-heart' => 'Social Responsibility', 74 75 // --- Convenience & Availability --- 76 'fa-solid fa-clock' => 'Quick Processing', 77 'fa-solid fa-store' => 'Local Pickup', 78 'fa-solid fa-map-marker-alt' => 'Find Us Easily', 79 'fa-solid fa-calendar-check' => 'Flexible Scheduling', 80 'fa-solid fa-credit-card' => 'Multiple Payment Methods', 81 82 // --- Technology & Innovation --- 83 'fa-solid fa-bolt' => 'Cutting Edge Tech', 84 'fa-solid fa-microchip' => 'Smart Features', 85 'fa-solid fa-robot' => 'AI Integration', 86 87 // --- Brand & Recognition --- 88 'fa-brands fa-apple' => 'Apple Compatible', 89 'fa-brands fa-android' => 'Android Friendly', 90 'fa-brands fa-paypal' => 'PayPal Accepted', 91 'fa-brands fa-cc-visa' => 'Visa Support', 92 'fa-brands fa-cc-mastercard' => 'Mastercard Support', 39 93 ); 40 94 } -
uniqselprotb/trunk/includes/constants/class-uniqselprotb-plugin-constant.php
r3357146 r3376726 68 68 const ALLOWED_SETTINGS_FIELDS = array( 'usp_0', 'usp_1', 'usp_2', 'usp_icon_0', 'usp_icon_1', 'usp_icon_2' ); 69 69 70 const ALLOWED_STYLE_FIELDS = array( ' background_color', 'text_color', 'font_size', 'font_size_unit', 'font_weight', 'font_style', 'padding_bottom', 'padding_top', 'padding_left', 'padding_right', 'padding_bottom_unit', 'padding_top_unit', 'padding_left_unit', 'padding_right_unit' );70 const ALLOWED_STYLE_FIELDS = array( 'is_sticky', 'background_color', 'text_color', 'font_size', 'font_size_unit', 'font_weight', 'font_style', 'padding_bottom', 'padding_top', 'padding_left', 'padding_right', 'padding_bottom_unit', 'padding_top_unit', 'padding_left_unit', 'padding_right_unit' ); 71 71 } -
uniqselprotb/trunk/includes/controllers/class-uniqselprotb-admin-controller.php
r3357146 r3376726 53 53 */ 54 54 public function uniqselprotb_enqueue_styles() { 55 if ( ! is_admin() ) { 56 return; 57 } 58 59 // Enqueue Font Awesome if not already loaded. 60 if ( ! wp_style_is( 'font-awesome-6', 'enqueued' ) ) { 61 wp_enqueue_style( 62 'font-awesome-6', 63 UNIQSELPROTB_PLUGIN_URL . 'assets/font-awesome/css/all.min.css', 64 array(), 65 '6.7.2' 66 ); 67 } 68 55 69 wp_enqueue_style( 56 70 'uniqselprotb-admin-style', … … 165 179 } 166 180 181 $is_sticky = $options_style['is_sticky'] ?? 0; 167 182 $background_color = $options_style['background_color'] ?? UNIQSELPROTB_Plugin_Constant::DEFAULT_BACKGROUND_COLOR; 168 183 $text_color = $options_style['text_color'] ?? UNIQSELPROTB_Plugin_Constant::DEFAULT_TEXT_COLOR; … … 348 363 $default_value = UNIQSELPROTB_Plugin_Constant::DEFAULT_PADDING_RIGHT_UNIT; 349 364 $sanitized_value = sanitize_text_field( $value ); 365 } elseif ( 'is_sticky' === $key ) { 366 $default_value = 0; 367 $sanitized_value = sanitize_text_field( $value ); 350 368 } 351 369 $sanitized_style[ $key ] = $sanitized_value ?? $default_value; -
uniqselprotb/trunk/includes/controllers/class-uniqselprotb-frontend-controller.php
r3357146 r3376726 61 61 UNIQSELPROTB_PLUGIN_URL . 'assets/css/uniqselprotb.css', 62 62 array(), 63 '1. 1.0',63 '1.4.0', 64 64 'all' 65 65 ); … … 72 72 UNIQSELPROTB_PLUGIN_URL . 'assets/js/uniqselprotb-frontend.js', 73 73 array( 'jquery' ), 74 '1. 1.0',74 '1.4.0', 75 75 array( 'strategy' => 'defer' ) 76 76 ); … … 80 80 UNIQSELPROTB_PLUGIN_URL . 'assets/js/uniqselprotb-frontend.js', 81 81 array( 'jquery' ), 82 '1. 1.0',82 '1.4.0', 83 83 true 84 84 ); … … 359 359 360 360 $usps = array(); 361 $options = get_option( 'uniqselprotb_settings', array() ); 362 363 if ( ! is_array( $options ) ) { 364 $options = array(); 365 } 366 367 if ( ! empty( $options ) ) { 368 $usps[ $current_language ] = $this->uniqselprotb_build_unique_selling_propositions_by_options( $options ); 361 $optionsSettings = get_option( 'uniqselprotb_settings', array() ); 362 363 if ( ! is_array( $optionsSettings ) ) { 364 $optionsSettings = array(); 365 } 366 367 if ( ! empty( $optionsSettings ) ) { 368 $usps[ $current_language ] = $this->uniqselprotb_build_unique_selling_propositions_by_options( $optionsSettings ); 369 } 370 371 $optionsStyle = get_option( 'uniqselprotb_style', array() ); 372 373 if ( ! is_array( $optionsStyle ) ) { 374 $optionsStyle = array(); 369 375 } 370 376 371 377 $current_usps = $usps[ $current_language ] ?? array(); 378 379 $isSticky = isset($optionsStyle['is_sticky']) && (bool) $optionsStyle['is_sticky']; 372 380 373 381 if ( ! empty( $current_usps ) ) { 374 382 $usp_count = count( $current_usps['usps'] ); 375 383 376 $html = '<div class="usps-top-banner header-usps ">';384 $html = '<div class="usps-top-banner header-usps' . ( $isSticky ? ' sticky' : '' ) . '">'; 377 385 $html .= '<div class="header-usps-column column-center full-width">'; 378 386 -
uniqselprotb/trunk/includes/views/uniqselprotb-form-settings.php
r3357146 r3376726 62 62 </td> 63 63 <td> 64 <span class="container-icon" data-index="<?php echo esc_attr( $i ) ?>"><i class="<?php echo esc_attr( $icon ) ?>"></i></span> 64 65 <?php 65 66 $name = 'uniqselprotb_settings[usp_icon_' . $i . ']'; 66 67 $css_id = 'icon-' . $i; 67 68 ?> 68 <select name="<?php echo esc_attr( $name ); ?>" id="<?php echo esc_attr( $css_id ); ?>"> 69 <?php 70 foreach ( $icons as $icon_class => $icon_name ) { 71 $selected = false; 72 if ( $icon_class === $icon ) { 73 $selected = true; 74 } 75 if ( $selected ) { 76 echo '<option value="' . esc_attr( $icon_class ) . '" selected><i class="' . sanitize_html_class( $icon_class ) . '"></i>' . esc_html( $icon_name ) . '</option>'; 77 } else { 78 echo '<option value="' . esc_attr( $icon_class ) . '">' . esc_html( $icon_name ) . '</option>'; 79 } 80 } 81 ?> 82 </select> 69 <input type="hidden" name="<?php echo esc_attr( $name ); ?>" value="<?php echo esc_attr( $icon ); ?>" id="<?php echo esc_attr( $css_id ); ?>"> 83 70 <span class="dashicons dashicons-trash delete-usp"></span> 84 71 </td> … … 95 82 <?php submit_button( 'Save Changes' ); ?> 96 83 </form> 84 <div class="modal-icons" id="modal-icons" style="border: 2px solid green;"> 85 <div class="modal-content"> 86 <span class="close">×</span> 87 88 <h3>Font Awesome</h3> 89 <div class="icons"> 90 <?php 91 92 foreach ( $icons as $icon_class => $icon_name ) { 93 94 95 $classes = explode( ' ', $icon_class ); 96 $classes = array_map( 'sanitize_html_class', $classes ); 97 $icon_class = implode( ' ', $classes ); 98 99 echo '<span class="modal-container-icon" data-icon="' . esc_attr( $icon_class ) . '"><i class="' . esc_attr( $icon_class ) . '"></i></span>'; 100 } 101 ?> 102 </div> 103 104 </div> 105 </div> 97 106 </div> -
uniqselprotb/trunk/includes/views/uniqselprotb-form-style.php
r3357146 r3376726 18 18 * View for form style in admin panel 19 19 * 20 * @var string $is_sticky 20 21 * @var string $background_color 21 22 * @var string $text_color … … 48 49 <h3>Style</h3> 49 50 <p id="style-description">Customize the look of your USP banner with options for text color and background color.</p> 50 <div class="container-table"> 51 <div class="container-table"> 52 <table class="form-table form-table-style"> 53 <tr> 54 <th style="width: 200px;">Sticky</th> 55 <th style="width: auto;"></th> 56 </tr> 57 <tr> 58 <td><label for="<?php echo esc_attr( 'uniqselprotb_is_sticky' ); ?>">Is Sticky</label></td> 59 <td> 60 <input 61 type="checkbox" 62 id="uniqselprotb_is_sticky" 63 class="unique-selling-propositions-top-banner-is-sticky-field" 64 name="uniqselprotb_style[is_sticky]" 65 value="1" 66 <?php checked( $is_sticky, 1 ); ?> 67 /> 68 69 </td> 70 </tr> 71 </table> 72 </div> 73 <div class="container-table"> 51 74 <table class="form-table form-table-style"> 52 75 <tr> -
uniqselprotb/trunk/readme.txt
r3357146 r3376726 4 4 Tags: unique selling propositions, banner 5 5 Requires at least: 6.0 6 Tested up to: 6.8 .26 Tested up to: 6.8 7 7 Requires PHP: 8.0 8 Stable tag: 1. 3.08 Stable tag: 1.4.0 9 9 License: GPLv2 or later 10 10 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 14 14 == Description == 15 15 16 Unique Selling Propositions Top Banner is a lightweight and user-friendly plugin that lets WordPress admins showcase u p to three keyselling propositions at the very top of their website. Perfect for quickly communicating benefits like free shipping, secure checkout, or fast delivery.16 Unique Selling Propositions Top Banner is a lightweight and user-friendly plugin that lets WordPress admins showcase unique selling propositions at the very top of their website. Perfect for quickly communicating benefits like free shipping, secure checkout, or fast delivery. 17 17 18 18 ### Features … … 94 94 == Changelog == 95 95 96 = 1.4.0 = 97 * Added more icons 98 * Added modal box with icons to select for USPs 99 * Added option to make the banner sticky 100 96 101 = 1.3.0 = 97 102 * Added support for more than 3 USPs -
uniqselprotb/trunk/uniqselprotb.php
r3357146 r3376726 20 20 * Description: Unique Selling Propositions Top Banner for WordPress 21 21 * with configurable USPs and icons. 22 * Version: 1. 3.022 * Version: 1.4.0 23 23 * Requires at least: 6.0 24 24 * Requires PHP: 8.0 25 * Tested up to: 6.8 .225 * Tested up to: 6.8 26 26 * Created: April 4, 2025 27 27 * Author: Ioanna Mitroulaki
Note: See TracChangeset
for help on using the changeset viewer.