%PDF- %PDF-
Direktori : /home/tradesc/www/relax/wp-content/plugins/wpforms-lite/assets/js/integrations/wpcode/ |
Current File : /home/tradesc/www/relax/wp-content/plugins/wpforms-lite/assets/js/integrations/wpcode/wpcode.min.js |
var WPFormsWPCode=window.WPFormsWPCode||function(t){const p={spinnerBlue:'<i class="wpforms-loading-spinner wpforms-loading-blue wpforms-loading-inline"></i>',spinnerWhite:'<i class="wpforms-loading-spinner wpforms-loading-white wpforms-loading-inline"></i>',snippetSearch:null,init(){t(p.ready)},ready(){p.snippetSearch=new List("wpforms-wpcode-snippets-list",{valueNames:["wpforms-wpcode-snippet-title"]}),p.events()},events(){t(".wpforms-wpcode-snippet-button").on("click",p.installSnippet),t(".wpforms-wpcode-popup-button").on("click",p.installPlugin),t("#wpforms-wpcode-snippet-search").on("keyup search",function(){p.searchSnippet(this)})},installSnippet(){var n,i=t(this);"edit"!==i.data("action")&&(n=i.width(),i.prev(".wpforms-wpcode-snippet-badge").addClass("wpforms-wpcode-installing-in-progress").text(wpformsWpcodeVars.installing_text),i.width(n).html(p.spinnerBlue))},searchSnippet(n){var n=t(n).val(),n=p.snippetSearch.search(n),i=t("#wpforms-wpcode-no-results");0===n.length?i.show():i.hide()},installPlugin(){var n,i,e,s=t(this);s.hasClass("disabled")||(e=s.attr("data-action"),n=s.attr("data-plugin"),i=JSON.stringify({overwrite_package:!0}),e="activate"===e?"wpforms_activate_addon":"wpforms_install_addon",s.width(s.width()).html(p.spinnerWhite).addClass("disabled"),s={action:e,nonce:wpforms_admin.nonce,plugin:n,args:i,type:"plugin"},t.post(wpforms_admin.ajax_url,s).done(function(){location.reload()}))}};return p}((document,window,jQuery));WPFormsWPCode.init();