jQuery(document).ready(function(a){a(".wp-mail-smtp-mailer input").click(function(){if(a(this).prop("disabled"))return!1;a(".wp-mail-smtp-mailer").removeClass("active"),a(this).parents(".wp-mail-smtp-mailer").addClass("active"),a(".wp-mail-smtp-mailer-option").addClass("hidden").removeClass("active"),a(".wp-mail-smtp-mailer-option-"+a(this).val()).addClass("active").removeClass("hidden")}),a(".wp-mail-smtp-mailer-image").click(function(){a(this).parents(".wp-mail-smtp-mailer").find("input").trigger("click")}),a(".wp-mail-smtp-setting-copy").click(function(t){t.preventDefault(),a("#"+a(this).data("source_id")).get(0).select(),document.execCommand("Copy")}),a("#wp-mail-smtp-setting-smtp-auth").change(function(){a("#wp-mail-smtp-setting-row-smtp-user, #wp-mail-smtp-setting-row-smtp-pass").toggleClass("inactive")}),a("#wp-mail-smtp-setting-row-smtp-encryption input").change(function(){var t=a(this),i=a("#wp-mail-smtp-setting-smtp-port");"tls"===t.val()?(i.val("587"),a("#wp-mail-smtp-setting-row-smtp-autotls").addClass("inactive")):("ssl"===t.val()?i.val("465"):i.val("25"),a("#wp-mail-smtp-setting-row-smtp-autotls").removeClass("inactive"))}),a("#wp-mail-smtp-wpforms-dismiss").on("click",function(){a.ajax({url:ajaxurl,dataType:"json",type:"POST",data:{action:"wp_mail_smtp_ajax",task:"wpforms_dismiss"}}).always(function(){a("#wp-mail-smtp-wpforms").fadeOut("fast")})}),a("#wp-mail-smtp-debug .error-log-toggle").on("click",function(t){t.preventDefault(),a("#wp-mail-smtp-debug .error-log-toggle").find(".dashicons").toggleClass("dashicons-arrow-right-alt2 dashicons-arrow-down-alt2"),a("#wp-mail-smtp-debug .error-log").slideToggle(),a("#wp-mail-smtp-debug .error-log-note").toggle()}),a("#wp-mail-smtp-gmail-remove").on("click",function(){return confirm(window.wp_mail_smtp.text_gmail_remove)})});