Plugin Directory

Changeset 3404647


Ignore:
Timestamp:
11/28/2025 05:57:54 AM (2 weeks ago)
Author:
coolplugins
Message:

Update to version 2.5.8 from GitHub

Location:
form-masks-for-elementor
Files:
10 edited
1 copied

Legend:

Unmodified
Added
Removed
  • form-masks-for-elementor/tags/2.5.8/admin/class-cfef-admin.php

    r3348867 r3404647  
    202202    }
    203203
     204    public function add_to_cfkef_enabled_elements( $new_items ) {
     205        $current = get_option( 'cfkef_enabled_elements', [] );
     206        $merged  = array_unique( array_merge( $current, (array) $new_items ) );
     207        update_option( 'cfkef_enabled_elements', $merged );
     208    }
     209
    204210    /**
    205211     * Register the settings for form elements.
     
    216222        register_setting( 'cfkef_form_elements_group', 'cfkef_toggle_all' );
    217223        register_setting( 'cfkef_form_elements_group', 'country_code' );
    218         register_setting( 'cfkef_form_elements_group', 'condtional_logic' );
     224        register_setting( 'cfkef_form_elements_group', 'conditional_logic' );
    219225        register_setting( 'cfkef_form_elements_group', 'form_input_mask' );
    220226        register_setting( 'cfkef_form_elements_group', 'input_mask' );
     
    224230        register_setting( 'cfkef_form_elements_group', 'cfkef_enable_elementor_pro_form' );
    225231
    226         if (!get_option('ccfef_plugin_initialized')) {
    227             // Get current enabled elements or empty array
    228                 update_option( 'country_code', true );
    229            
    230             // Set initialization flag to avoid repeating
    231             update_option('ccfef_plugin_initialized', true);
    232         }
    233 
    234         if (!get_option('fme_plugin_initialized')) {
    235             // Get current enabled elements or empty array
    236 
    237                 update_option( 'form_input_mask', true );
    238            
    239                 // Set initialization flag to avoid repeating
    240                 update_option('fme_plugin_initialized', true);
    241            
    242         }
    243 
    244         if (!get_option('mfe_plugin_initialized')) {
    245             // Get current enabled elements or empty array
    246 
    247                 update_option( 'input_mask', true );
    248            
    249                 // Set initialization flag to avoid repeating
    250                 update_option('mfe_plugin_initialized', true);
    251            
     232        if ( ! get_option( 'ccfef_plugin_initialized' ) ) {
     233
     234            $this->add_to_cfkef_enabled_elements( ['country_code'] );
     235
     236            update_option( 'ccfef_plugin_initialized', true );
     237
     238        } else {
     239
     240            if ( ! get_option( 'ccfef_migrate_done' ) ) {
     241
     242                $val = get_option( 'country_code', null );
     243
     244                if ( ! is_null( $val ) && $val ) {
     245                    // Option exists AND is true
     246                    $this->add_to_cfkef_enabled_elements( ['country_code'] );
     247                }
     248
     249                update_option( 'ccfef_migrate_done', true );
     250            }
     251        }
     252
     253
     254        /**
     255         * 2. FME initialization / migration
     256         */
     257        if ( ! get_option( 'fme_plugin_initialized' ) ) {
     258
     259            $this->add_to_cfkef_enabled_elements( ['form_input_mask'] );
     260
     261            update_option( 'fme_plugin_initialized', true );
     262
     263        } else {
     264
     265            if ( ! get_option( 'fme_migrate_done' ) ) {
     266
     267                $val = get_option( 'form_input_mask', null );
     268
     269                if ( ! is_null( $val ) && $val ) {
     270                    // Option exists AND is true
     271                    $this->add_to_cfkef_enabled_elements( ['form_input_mask'] );
     272                }
     273
     274                update_option( 'fme_migrate_done', true );
     275            }
     276        }
     277
     278
     279        /**
     280         * 3. MFE initialization / migration
     281         */
     282        if ( ! get_option( 'mfe_plugin_initialized' ) ) {
     283
     284            $this->add_to_cfkef_enabled_elements( ['input_mask'] );
     285
     286            update_option( 'mfe_plugin_initialized', true );
     287
     288        } else {
     289
     290            if ( ! get_option( 'mfe_migrate_done' ) ) {
     291
     292                $val = get_option( 'input_mask', null );
     293
     294                if ( ! is_null( $val ) && $val ) {
     295                    // Option exists AND is true
     296                    $this->add_to_cfkef_enabled_elements( ['input_mask'] );
     297                }
     298
     299                update_option( 'mfe_migrate_done', true );
     300            }
    252301        }
    253302    }
  • form-masks-for-elementor/tags/2.5.8/admin/views/form-elements.php

    r3348867 r3404647  
    183183
    184184$condition_plugin_features = array(
    185     'condtional_logic' => array(
     185    'conditional_logic' => array(
    186186        'label' => __('Conditional Logic', 'cool-formkit'),
    187187        'how_to' => str_replace('utm_source=cfkef_plugin', 'utm_source=' . $first_plugin, 'https://docs.coolplugins.net/doc/elementor-form-conditional-fields/?utm_source=cfkef_plugin&utm_medium=inside&utm_campaign=docs&utm_content=dashboard'),
     
    522522
    523523                                            <label class="cfkef-toggle-switch" style="<?php echo !$is_condtional_field_active ? 'opacity: 0.2; ' : ''; ?>">
    524                                                 <input type="checkbox" name="<?php echo esc_attr($key); ?>" value="1" <?php checked(get_option('condtional_logic'));
    525                                                                                                                         ?> class="cfkef-element-toggle"
     524                                                <input type="checkbox" name="cfkef_enabled_elements[]" value="<?php echo esc_attr($key); ?>" <?php checked(in_array($key, $enabled_elements));?> class="cfkef-element-toggle"
    526525                                                    <?php disabled(!$is_condtional_field_active); ?>>
    527526                                                <?php if (!empty($element['pro'])): ?>
     
    724723
    725724                                            <label class="cfkef-toggle-switch" style="<?php echo !$is_country_field_active ? 'opacity: 0.2; ' : ''; ?>">
    726                                                 <input type="checkbox" name="<?php echo esc_attr($key); ?>" value="1" <?php checked(get_option('country_code'));
    727                                                                                                                         ?> class="cfkef-element-toggle"
     725                                                <input type="checkbox" name="cfkef_enabled_elements[]" value="<?php echo esc_attr($key); ?>" <?php checked(in_array($key, $enabled_elements));?> class="cfkef-element-toggle"
    728726                                                    <?php disabled(!$is_country_field_active); ?>>
    729727                                                <?php if (!empty($element['pro'])): ?>
     
    10421040
    10431041                                                <label class="cfkef-toggle-switch" style="<?php echo !$is_form_mask_active ? 'opacity: 0.2; ' : ''; ?>">
    1044                                                     <input type="checkbox" name="<?php echo esc_attr($key); ?>" value="1" <?php checked(get_option('form_input_mask'));
    1045                                                                                                                             ?> class="cfkef-element-toggle"
     1042                                                    <input type="checkbox" name="cfkef_enabled_elements[]" value="<?php echo esc_attr($key); ?>" <?php checked(in_array($key, $enabled_elements));  ?> class="cfkef-element-toggle"
    10461043                                                        <?php disabled(!$is_form_mask_active); ?>>
    10471044                                                    <?php if (!empty($element['pro'])): ?>
  • form-masks-for-elementor/tags/2.5.8/assets/js/admin-script.js

    r3359005 r3404647  
    8282        if (!headerButton || bodyInputs.length === 0) return;
    8383
    84         const input1 = wrapper.querySelector('input[name="condtional_logic"]');
    85         const input2 = wrapper.querySelector('input[name="country_code"]');
    86         const input3 = wrapper.querySelector('input[name="form_input_mask"]');
    87         const input4 = wrapper.querySelector('input[name="input_mask"]');
     84        const input1 = wrapper.querySelector('input[value="conditional_logic"]');
     85        const input2 = wrapper.querySelector('input[value="country_code"]');
     86        const input3 = wrapper.querySelector('input[value="form_input_mask"]');
     87        const input4 = wrapper.querySelector('input[value="input_mask"]');
    8888
    8989
     
    9595        }
    9696
     97       
    9798
    9899        bodyInputs.forEach(input => {
    99100
    100 
    101 
    102101            input.addEventListener('change', function () {
    103102
    104103
    105                 if (input1 && input.name === 'condtional_logic') {
     104                if (input1 && input.value === 'conditional_logic') {
    106105
    107106
    108107                    if(input1.checked || !input1.checked){
    109108
    110                         jQuery('input[name="condtional_logic"]').parent().parent().parent().parent().parent().find(".button-primary").addClass('shake-effect');
     109                        jQuery('input[value="conditional_logic"]').parent().parent().parent().parent().parent().find(".button-primary").addClass('shake-effect');
    111110                    }
    112111                }
    113112               
    114                 else if (input2 && input.name === 'country_code') {
     113                else if (input2 && input.value === 'country_code') {
    115114
    116115                    if(input2.checked || !input2.checked){
    117116
    118                         jQuery('input[name="country_code"]').parent().parent().parent().parent().parent().find(".button-primary").addClass('shake-effect');
    119                     }
    120                 }
    121 
    122                 else if (input3 && input.name === 'form_input_mask') {
     117                        jQuery('input[value="country_code"]').parent().parent().parent().parent().parent().find(".button-primary").addClass('shake-effect');
     118                    }
     119                }
     120
     121                else if (input3 && input.value === 'form_input_mask') {
    123122
    124123                    if(input3.checked || !input3.checked){
    125124
    126                         jQuery('input[name="form_input_mask"]').parent().parent().parent().parent().parent().find(".button-primary").addClass('shake-effect');
    127                     }
    128                 }
    129 
    130                 else if (input4 && input.name === 'input_mask') {
     125                        jQuery('input[value="form_input_mask"]').parent().parent().parent().parent().parent().find(".button-primary").addClass('shake-effect');
     126                    }
     127                }
     128
     129                else if (input4 && input.value === 'input_mask') {
    131130
    132131                    if(input4.checked || !input4.checked){
    133132
    134                         jQuery('input[name="input_mask"]').parent().parent().parent().parent().parent().find(".button-primary").addClass('shake-effect');
     133                        jQuery('input[value="input_mask"]').parent().parent().parent().parent().parent().find(".button-primary").addClass('shake-effect');
    135134                    }
    136135                }
     
    165164                // Append button
    166165                if (action === 'activate') {
    167                     tooltip.innerHTML += `<button class="cfkef-activate-plugin-btn" data-slug="${slug}" data-init="${init}">Activate Plugin</button>`;
     166                    const button = document.createElement('button');
     167                    button.className = 'cfkef-activate-plugin-btn';
     168                    button.dataset.slug = slug;
     169                    button.dataset.init = init;
     170                    button.textContent = 'Activate Plugin';
     171                    tooltip.appendChild(button);
    168172                } else if (action === 'install') {
    169                     let extraCss;
    170                     if(el.classList.contains('need-install') && el.dataset.slug === 'elementor-pro'){
    171                         extraCss = 'redirect-elementor-page'
    172                     }
    173                     let tooltip_text = tooltip.innerHTML;
    174 
    175                     tooltip_text = tooltip_text.replace('Install Plugin', '');
    176 
    177                     tooltip.innerHTML = "";
    178 
    179                     tooltip.innerHTML = tooltip_text + `<button class="cfkef-install-plugin-btn ${extraCss}" data-slug="${slug}" data-init="${init}">Install Plugin</button>`;
     173                    let extraCss = '';
     174                    if (el.classList.contains('need-install') && el.dataset.slug === 'elementor-pro') {
     175                        extraCss = 'redirect-elementor-page';
     176                    }
     177
     178                    // Clear tooltip text safely
     179                    const tooltipText = tooltip.textContent.replace('Install Plugin', '');
     180                    tooltip.textContent = tooltipText;
     181
     182                    const button = document.createElement('button');
     183                    button.className = `cfkef-install-plugin-btn ${extraCss}`;
     184                    button.dataset.slug = slug;
     185                    button.dataset.init = init;
     186                    button.textContent = 'Install Plugin';
     187                    tooltip.appendChild(button);
    180188                }
    181189            }
     
    228236                                if (res) {
    229237                                    window.location.reload();
    230                                 } 
     238                                }
    231239                            },
    232240                            error: function () {
  • form-masks-for-elementor/tags/2.5.8/form-masks-for-elementor.php

    r3379239 r3404647  
    66 * Author: Cool Plugins
    77 * Author URI: https://coolplugins.net/?utm_source=fim_plugin&utm_medium=inside&utm_campaign=author_page&utm_content=plugins_list
    8  * Version: 2.5.7
     8 * Version: 2.5.8
    99 * Requires at least: 5.5
    1010 * Requires PHP: 7.4
     
    1313 * License URI: http://www.gnu.org/licenses/gpl-2.0.txt
    1414 * Requires Plugins: elementor
    15  * Elementor tested up to: 3.32.4
    16  * Elementor Pro tested up to: 3.32.2
     15 * Elementor tested up to: 3.33.2
     16 * Elementor Pro tested up to: 3.32.1
    1717 */
    1818
     
    2323}
    2424
    25 define( 'FME_VERSION', '2.5.7' );
     25define( 'FME_VERSION', '2.5.8' );
    2626define( 'FME_FILE', __FILE__ );
    2727define( 'FME_PLUGIN_BASE', plugin_basename( FME_FILE ) );
     
    6969        }
    7070    }
     71
     72    private function is_field_enabled($field_key) {
     73            $enabled_elements = get_option('cfkef_enabled_elements', array());
     74            return in_array(sanitize_key($field_key), array_map('sanitize_key', $enabled_elements));
     75        }
     76
    7177
    7278    public function plugin_loads(){
     
    196202    private function initialize_plugin() {
    197203
    198         if(get_option('form_input_mask', true)){
     204        if($this->is_field_enabled('form_input_mask')){
    199205
    200206            require_once FME_PLUGIN_PATH . 'includes/class-fme-plugin.php';
  • form-masks-for-elementor/tags/2.5.8/readme.txt

    r3379239 r3404647  
    44Tags: mask, input masks, elementor form, elementor, elementor form builder
    55Requires at least: 5.0
    6 Tested up to: 6.8.2
     6Tested up to: 6.8.3
    77Requires PHP: 7.2
    8 Stable tag: 2.5.7
     8Stable tag: 2.5.8
    99License: GPLv2 or later
    1010License URI: https://www.gnu.org/licenses/gpl-2.0.html
    11 Elementor tested up to: 3.32.4
    12 Elementor Pro tested up to: 3.32.2
     11Elementor tested up to: 3.33.2
     12Elementor Pro tested up to: 3.33.1
    1313
    1414Add input masks to Elementor Pro or Hello Plus form fields - phone, date, time, credit card, CPF, CNPJ, CEP & more for accurate entries.
     
    192192== Changelog ==
    193193
     194= 2.5.8 - Nov 28, 2025 =
     195- Fixed: - Setting ID mismatch causing updates to not reflect in all versions.
     196
    194197= 2.5.7 - Oct 16, 2025 =
    195198- Fixed: - form submission issue with required hidden mask field.
  • form-masks-for-elementor/trunk/admin/class-cfef-admin.php

    r3348867 r3404647  
    202202    }
    203203
     204    public function add_to_cfkef_enabled_elements( $new_items ) {
     205        $current = get_option( 'cfkef_enabled_elements', [] );
     206        $merged  = array_unique( array_merge( $current, (array) $new_items ) );
     207        update_option( 'cfkef_enabled_elements', $merged );
     208    }
     209
    204210    /**
    205211     * Register the settings for form elements.
     
    216222        register_setting( 'cfkef_form_elements_group', 'cfkef_toggle_all' );
    217223        register_setting( 'cfkef_form_elements_group', 'country_code' );
    218         register_setting( 'cfkef_form_elements_group', 'condtional_logic' );
     224        register_setting( 'cfkef_form_elements_group', 'conditional_logic' );
    219225        register_setting( 'cfkef_form_elements_group', 'form_input_mask' );
    220226        register_setting( 'cfkef_form_elements_group', 'input_mask' );
     
    224230        register_setting( 'cfkef_form_elements_group', 'cfkef_enable_elementor_pro_form' );
    225231
    226         if (!get_option('ccfef_plugin_initialized')) {
    227             // Get current enabled elements or empty array
    228                 update_option( 'country_code', true );
    229            
    230             // Set initialization flag to avoid repeating
    231             update_option('ccfef_plugin_initialized', true);
    232         }
    233 
    234         if (!get_option('fme_plugin_initialized')) {
    235             // Get current enabled elements or empty array
    236 
    237                 update_option( 'form_input_mask', true );
    238            
    239                 // Set initialization flag to avoid repeating
    240                 update_option('fme_plugin_initialized', true);
    241            
    242         }
    243 
    244         if (!get_option('mfe_plugin_initialized')) {
    245             // Get current enabled elements or empty array
    246 
    247                 update_option( 'input_mask', true );
    248            
    249                 // Set initialization flag to avoid repeating
    250                 update_option('mfe_plugin_initialized', true);
    251            
     232        if ( ! get_option( 'ccfef_plugin_initialized' ) ) {
     233
     234            $this->add_to_cfkef_enabled_elements( ['country_code'] );
     235
     236            update_option( 'ccfef_plugin_initialized', true );
     237
     238        } else {
     239
     240            if ( ! get_option( 'ccfef_migrate_done' ) ) {
     241
     242                $val = get_option( 'country_code', null );
     243
     244                if ( ! is_null( $val ) && $val ) {
     245                    // Option exists AND is true
     246                    $this->add_to_cfkef_enabled_elements( ['country_code'] );
     247                }
     248
     249                update_option( 'ccfef_migrate_done', true );
     250            }
     251        }
     252
     253
     254        /**
     255         * 2. FME initialization / migration
     256         */
     257        if ( ! get_option( 'fme_plugin_initialized' ) ) {
     258
     259            $this->add_to_cfkef_enabled_elements( ['form_input_mask'] );
     260
     261            update_option( 'fme_plugin_initialized', true );
     262
     263        } else {
     264
     265            if ( ! get_option( 'fme_migrate_done' ) ) {
     266
     267                $val = get_option( 'form_input_mask', null );
     268
     269                if ( ! is_null( $val ) && $val ) {
     270                    // Option exists AND is true
     271                    $this->add_to_cfkef_enabled_elements( ['form_input_mask'] );
     272                }
     273
     274                update_option( 'fme_migrate_done', true );
     275            }
     276        }
     277
     278
     279        /**
     280         * 3. MFE initialization / migration
     281         */
     282        if ( ! get_option( 'mfe_plugin_initialized' ) ) {
     283
     284            $this->add_to_cfkef_enabled_elements( ['input_mask'] );
     285
     286            update_option( 'mfe_plugin_initialized', true );
     287
     288        } else {
     289
     290            if ( ! get_option( 'mfe_migrate_done' ) ) {
     291
     292                $val = get_option( 'input_mask', null );
     293
     294                if ( ! is_null( $val ) && $val ) {
     295                    // Option exists AND is true
     296                    $this->add_to_cfkef_enabled_elements( ['input_mask'] );
     297                }
     298
     299                update_option( 'mfe_migrate_done', true );
     300            }
    252301        }
    253302    }
  • form-masks-for-elementor/trunk/admin/views/form-elements.php

    r3348867 r3404647  
    183183
    184184$condition_plugin_features = array(
    185     'condtional_logic' => array(
     185    'conditional_logic' => array(
    186186        'label' => __('Conditional Logic', 'cool-formkit'),
    187187        'how_to' => str_replace('utm_source=cfkef_plugin', 'utm_source=' . $first_plugin, 'https://docs.coolplugins.net/doc/elementor-form-conditional-fields/?utm_source=cfkef_plugin&utm_medium=inside&utm_campaign=docs&utm_content=dashboard'),
     
    522522
    523523                                            <label class="cfkef-toggle-switch" style="<?php echo !$is_condtional_field_active ? 'opacity: 0.2; ' : ''; ?>">
    524                                                 <input type="checkbox" name="<?php echo esc_attr($key); ?>" value="1" <?php checked(get_option('condtional_logic'));
    525                                                                                                                         ?> class="cfkef-element-toggle"
     524                                                <input type="checkbox" name="cfkef_enabled_elements[]" value="<?php echo esc_attr($key); ?>" <?php checked(in_array($key, $enabled_elements));?> class="cfkef-element-toggle"
    526525                                                    <?php disabled(!$is_condtional_field_active); ?>>
    527526                                                <?php if (!empty($element['pro'])): ?>
     
    724723
    725724                                            <label class="cfkef-toggle-switch" style="<?php echo !$is_country_field_active ? 'opacity: 0.2; ' : ''; ?>">
    726                                                 <input type="checkbox" name="<?php echo esc_attr($key); ?>" value="1" <?php checked(get_option('country_code'));
    727                                                                                                                         ?> class="cfkef-element-toggle"
     725                                                <input type="checkbox" name="cfkef_enabled_elements[]" value="<?php echo esc_attr($key); ?>" <?php checked(in_array($key, $enabled_elements));?> class="cfkef-element-toggle"
    728726                                                    <?php disabled(!$is_country_field_active); ?>>
    729727                                                <?php if (!empty($element['pro'])): ?>
     
    10421040
    10431041                                                <label class="cfkef-toggle-switch" style="<?php echo !$is_form_mask_active ? 'opacity: 0.2; ' : ''; ?>">
    1044                                                     <input type="checkbox" name="<?php echo esc_attr($key); ?>" value="1" <?php checked(get_option('form_input_mask'));
    1045                                                                                                                             ?> class="cfkef-element-toggle"
     1042                                                    <input type="checkbox" name="cfkef_enabled_elements[]" value="<?php echo esc_attr($key); ?>" <?php checked(in_array($key, $enabled_elements));  ?> class="cfkef-element-toggle"
    10461043                                                        <?php disabled(!$is_form_mask_active); ?>>
    10471044                                                    <?php if (!empty($element['pro'])): ?>
  • form-masks-for-elementor/trunk/assets/js/admin-script.js

    r3359005 r3404647  
    8282        if (!headerButton || bodyInputs.length === 0) return;
    8383
    84         const input1 = wrapper.querySelector('input[name="condtional_logic"]');
    85         const input2 = wrapper.querySelector('input[name="country_code"]');
    86         const input3 = wrapper.querySelector('input[name="form_input_mask"]');
    87         const input4 = wrapper.querySelector('input[name="input_mask"]');
     84        const input1 = wrapper.querySelector('input[value="conditional_logic"]');
     85        const input2 = wrapper.querySelector('input[value="country_code"]');
     86        const input3 = wrapper.querySelector('input[value="form_input_mask"]');
     87        const input4 = wrapper.querySelector('input[value="input_mask"]');
    8888
    8989
     
    9595        }
    9696
     97       
    9798
    9899        bodyInputs.forEach(input => {
    99100
    100 
    101 
    102101            input.addEventListener('change', function () {
    103102
    104103
    105                 if (input1 && input.name === 'condtional_logic') {
     104                if (input1 && input.value === 'conditional_logic') {
    106105
    107106
    108107                    if(input1.checked || !input1.checked){
    109108
    110                         jQuery('input[name="condtional_logic"]').parent().parent().parent().parent().parent().find(".button-primary").addClass('shake-effect');
     109                        jQuery('input[value="conditional_logic"]').parent().parent().parent().parent().parent().find(".button-primary").addClass('shake-effect');
    111110                    }
    112111                }
    113112               
    114                 else if (input2 && input.name === 'country_code') {
     113                else if (input2 && input.value === 'country_code') {
    115114
    116115                    if(input2.checked || !input2.checked){
    117116
    118                         jQuery('input[name="country_code"]').parent().parent().parent().parent().parent().find(".button-primary").addClass('shake-effect');
    119                     }
    120                 }
    121 
    122                 else if (input3 && input.name === 'form_input_mask') {
     117                        jQuery('input[value="country_code"]').parent().parent().parent().parent().parent().find(".button-primary").addClass('shake-effect');
     118                    }
     119                }
     120
     121                else if (input3 && input.value === 'form_input_mask') {
    123122
    124123                    if(input3.checked || !input3.checked){
    125124
    126                         jQuery('input[name="form_input_mask"]').parent().parent().parent().parent().parent().find(".button-primary").addClass('shake-effect');
    127                     }
    128                 }
    129 
    130                 else if (input4 && input.name === 'input_mask') {
     125                        jQuery('input[value="form_input_mask"]').parent().parent().parent().parent().parent().find(".button-primary").addClass('shake-effect');
     126                    }
     127                }
     128
     129                else if (input4 && input.value === 'input_mask') {
    131130
    132131                    if(input4.checked || !input4.checked){
    133132
    134                         jQuery('input[name="input_mask"]').parent().parent().parent().parent().parent().find(".button-primary").addClass('shake-effect');
     133                        jQuery('input[value="input_mask"]').parent().parent().parent().parent().parent().find(".button-primary").addClass('shake-effect');
    135134                    }
    136135                }
     
    165164                // Append button
    166165                if (action === 'activate') {
    167                     tooltip.innerHTML += `<button class="cfkef-activate-plugin-btn" data-slug="${slug}" data-init="${init}">Activate Plugin</button>`;
     166                    const button = document.createElement('button');
     167                    button.className = 'cfkef-activate-plugin-btn';
     168                    button.dataset.slug = slug;
     169                    button.dataset.init = init;
     170                    button.textContent = 'Activate Plugin';
     171                    tooltip.appendChild(button);
    168172                } else if (action === 'install') {
    169                     let extraCss;
    170                     if(el.classList.contains('need-install') && el.dataset.slug === 'elementor-pro'){
    171                         extraCss = 'redirect-elementor-page'
    172                     }
    173                     let tooltip_text = tooltip.innerHTML;
    174 
    175                     tooltip_text = tooltip_text.replace('Install Plugin', '');
    176 
    177                     tooltip.innerHTML = "";
    178 
    179                     tooltip.innerHTML = tooltip_text + `<button class="cfkef-install-plugin-btn ${extraCss}" data-slug="${slug}" data-init="${init}">Install Plugin</button>`;
     173                    let extraCss = '';
     174                    if (el.classList.contains('need-install') && el.dataset.slug === 'elementor-pro') {
     175                        extraCss = 'redirect-elementor-page';
     176                    }
     177
     178                    // Clear tooltip text safely
     179                    const tooltipText = tooltip.textContent.replace('Install Plugin', '');
     180                    tooltip.textContent = tooltipText;
     181
     182                    const button = document.createElement('button');
     183                    button.className = `cfkef-install-plugin-btn ${extraCss}`;
     184                    button.dataset.slug = slug;
     185                    button.dataset.init = init;
     186                    button.textContent = 'Install Plugin';
     187                    tooltip.appendChild(button);
    180188                }
    181189            }
     
    228236                                if (res) {
    229237                                    window.location.reload();
    230                                 } 
     238                                }
    231239                            },
    232240                            error: function () {
  • form-masks-for-elementor/trunk/form-masks-for-elementor.php

    r3379239 r3404647  
    66 * Author: Cool Plugins
    77 * Author URI: https://coolplugins.net/?utm_source=fim_plugin&utm_medium=inside&utm_campaign=author_page&utm_content=plugins_list
    8  * Version: 2.5.7
     8 * Version: 2.5.8
    99 * Requires at least: 5.5
    1010 * Requires PHP: 7.4
     
    1313 * License URI: http://www.gnu.org/licenses/gpl-2.0.txt
    1414 * Requires Plugins: elementor
    15  * Elementor tested up to: 3.32.4
    16  * Elementor Pro tested up to: 3.32.2
     15 * Elementor tested up to: 3.33.2
     16 * Elementor Pro tested up to: 3.32.1
    1717 */
    1818
     
    2323}
    2424
    25 define( 'FME_VERSION', '2.5.7' );
     25define( 'FME_VERSION', '2.5.8' );
    2626define( 'FME_FILE', __FILE__ );
    2727define( 'FME_PLUGIN_BASE', plugin_basename( FME_FILE ) );
     
    6969        }
    7070    }
     71
     72    private function is_field_enabled($field_key) {
     73            $enabled_elements = get_option('cfkef_enabled_elements', array());
     74            return in_array(sanitize_key($field_key), array_map('sanitize_key', $enabled_elements));
     75        }
     76
    7177
    7278    public function plugin_loads(){
     
    196202    private function initialize_plugin() {
    197203
    198         if(get_option('form_input_mask', true)){
     204        if($this->is_field_enabled('form_input_mask')){
    199205
    200206            require_once FME_PLUGIN_PATH . 'includes/class-fme-plugin.php';
  • form-masks-for-elementor/trunk/readme.txt

    r3379239 r3404647  
    44Tags: mask, input masks, elementor form, elementor, elementor form builder
    55Requires at least: 5.0
    6 Tested up to: 6.8.2
     6Tested up to: 6.8.3
    77Requires PHP: 7.2
    8 Stable tag: 2.5.7
     8Stable tag: 2.5.8
    99License: GPLv2 or later
    1010License URI: https://www.gnu.org/licenses/gpl-2.0.html
    11 Elementor tested up to: 3.32.4
    12 Elementor Pro tested up to: 3.32.2
     11Elementor tested up to: 3.33.2
     12Elementor Pro tested up to: 3.33.1
    1313
    1414Add input masks to Elementor Pro or Hello Plus form fields - phone, date, time, credit card, CPF, CNPJ, CEP & more for accurate entries.
     
    192192== Changelog ==
    193193
     194= 2.5.8 - Nov 28, 2025 =
     195- Fixed: - Setting ID mismatch causing updates to not reflect in all versions.
     196
    194197= 2.5.7 - Oct 16, 2025 =
    195198- Fixed: - form submission issue with required hidden mask field.
Note: See TracChangeset for help on using the changeset viewer.