Contact Form Plugin – Fastest Contact Form Builder Plugin for WordPress by Fluent Forms - Version 3.6.73

Version Description

(Date: May 27, 2021) = * Hot Fix: Form hide issue fixed after submission * A big update is coming soon

Download this release

Release Info

Developer techjewel
Plugin Icon 128x128 Contact Form Plugin – Fastest Contact Form Builder Plugin for WordPress by Fluent Forms
Version 3.6.73
Comparing to
See all releases

Code changes from version 3.6.72 to 3.6.73

Files changed (4) hide show
  1. fluentform.php +3 -3
  2. glue.json +1 -1
  3. public/js/form-submission.js +1 -1
  4. readme.txt +5 -1
fluentform.php CHANGED
@@ -2,9 +2,9 @@
2
  /*
3
  Plugin Name: Fluent Forms
4
  Description: Contact Form By Fluent Forms is the advanced Contact form plugin with drag and drop, multi column supported form builder plugin
5
- Version: 3.6.72
6
  Author: Contact Form - WPManageNinja LLC
7
- Author URI: https://wpfluentforms.com
8
  Plugin URI: https://wpmanageninja.com/wp-fluent-form/
9
  License: GPLv2 or later
10
  Text Domain: fluentform
@@ -16,7 +16,7 @@ defined('ABSPATH') or die;
16
  defined('FLUENTFORM') or define('FLUENTFORM', true);
17
  define('FLUENTFORM_DIR_PATH', plugin_dir_path(__FILE__));
18
 
19
- defined('FLUENTFORM_VERSION') or define('FLUENTFORM_VERSION', '3.6.72');
20
 
21
  if (!defined('FLUENTFORM_HAS_NIA')) {
22
  define('FLUENTFORM_HAS_NIA', true);
2
  /*
3
  Plugin Name: Fluent Forms
4
  Description: Contact Form By Fluent Forms is the advanced Contact form plugin with drag and drop, multi column supported form builder plugin
5
+ Version: 3.6.73
6
  Author: Contact Form - WPManageNinja LLC
7
+ Author URI: https://fluentforms.com
8
  Plugin URI: https://wpmanageninja.com/wp-fluent-form/
9
  License: GPLv2 or later
10
  Text Domain: fluentform
16
  defined('FLUENTFORM') or define('FLUENTFORM', true);
17
  define('FLUENTFORM_DIR_PATH', plugin_dir_path(__FILE__));
18
 
19
+ defined('FLUENTFORM_VERSION') or define('FLUENTFORM_VERSION', '3.6.73');
20
 
21
  if (!defined('FLUENTFORM_HAS_NIA')) {
22
  define('FLUENTFORM_HAS_NIA', true);
glue.json CHANGED
@@ -2,7 +2,7 @@
2
  "plugin_name": "FluentForm",
3
  "plugin_slug": "fluentform",
4
  "plugin_text_domain": "fluentform",
5
- "plugin_version": "3.6.70",
6
  "plugin_description": "The most advanced drag and drop form builder plugin for WordPress",
7
  "plugin_uri": "https://wpfluentforms.com",
8
  "plugin_license": "GPLv2 or later",
2
  "plugin_name": "FluentForm",
3
  "plugin_slug": "fluentform",
4
  "plugin_text_domain": "fluentform",
5
+ "plugin_version": "3.6.73",
6
  "plugin_description": "The most advanced drag and drop form builder plugin for WordPress",
7
  "plugin_uri": "https://wpfluentforms.com",
8
  "plugin_license": "GPLv2 or later",
public/js/form-submission.js CHANGED
@@ -1 +1 @@
1
- !function(e){var t={};function r(n){if(t[n])return t[n].exports;var i=t[n]={i:n,l:!1,exports:{}};return e[n].call(i.exports,i,i.exports,r),i.l=!0,i.exports}r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)r.d(n,i,function(t){return e[t]}.bind(null,i));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="/",r(r.s=563)}({563:function(e,t,r){e.exports=r(564)},564:function(e,t){function r(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function n(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?r(Object(n),!0).forEach((function(t){i(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function i(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}jQuery(document).ready((function(){window.fluentFormrecaptchaSuccessCallback=function(e){if(window.innerWidth<768&&/iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream){var t=jQuery(".g-recaptcha").filter((function(t,r){return grecaptcha.getResponse(t)==e}));t.length&&jQuery("html, body").animate({scrollTop:t.first().offset().top-jQuery(window).height()/2},0)}},window.ffValidationError=function(){var e=function(){};return(e.prototype=Object.create(Error.prototype)).constructor=e,e}(),window.ff_helper={numericVal:function(e){if(e.hasClass("ff_numeric")){var t=JSON.parse(e.attr("data-formatter"));return currency(e.val(),t).value}return e.val()||0},formatCurrency:function(e,t){if(e.hasClass("ff_numeric")){var r=JSON.parse(e.attr("data-formatter"));return currency(t,r).format()}return t}},function(e,t){e||(e={}),e.stepAnimationDuration=parseInt(e.stepAnimationDuration),window.fluentFormApp=function(r){var n=r.attr("data-form_instance"),a=window["fluent_form_"+n];if(a){var o,s,f,c,l,u,d,p,m,h,v,g,_,b,w,y,x=a.form_id_selector,k="."+n;return o=i,s=function(){return t("body").find("form"+k)},c=function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"next";r.trigger("update_slider",{goBackToStep:e,animDuration:t,isScrollTop:n,actionType:i})},l=function(e){e.find(".ff-btn-submit").addClass("disabled").addClass("ff-working").prop("disabled",!0)},u=function(){"yes"!=r.attr("data-ff_reinit")&&(t(document).on("submit",k,(function(r){r.preventDefault(),function(r){try{var n=r.find(":input").filter((function(e,r){return!t(r).closest(".has-conditions").hasClass("ff_excluded")}));v(n);var i={data:n.serialize(),action:"fluentform_submit",form_id:r.data("form_id")};if(r.find(".ff-el-recaptcha.g-recaptcha").length){var o=d(i.form_id);o&&(i.data+="&"+t.param({"g-recaptcha-response":grecaptcha.getResponse(o)}))}if(t.each(r.find("[type=file]"),(function(e,r){var n={},a=r.name+"[]";n[a]=[],t(r).closest("div").find(".ff-uploaded-list").find(".ff-upload-preview[data-src]").each((function(e,r){n[a][e]=t(this).data("src")})),t.each(n,(function(e,r){if(r.length){var n={};n[e]=r,i.data+="&"+t.param(n)}}))})),r.find(".ff_uploading").length){var s=t("<div/>",{class:"error text-danger"}),f=t("<span/>",{class:"error-clear",html:"&times;",click:function(e){return t(k+"_errors").html("")}}),u=t("<span/>",{class:"error-text",text:"File upload in progress. Please wait..."});return t(k+"_errors").html(s.append(u,f)).show()}t(k+"_success").remove(),t(k+"_errors").html(""),r.find(".error").html(""),r.parent().find(".ff-errors-in-stack").hide(),l(r);var p=(_="t="+Date.now(),b=e.ajaxUrl,b+=(b.split("?")[1]?"&":"?")+_);t.post(p,i).then((function(e){if(!e||!e.data||!e.data.result)return r.trigger("fluentform_submission_failed",{form:r,response:e}),void g(e);if(e.data.nextAction)r.trigger("fluentform_next_action_"+e.data.nextAction,{form:r,response:e});else{if(r.trigger("fluentform_submission_success",{form:r,config:a,response:e}),jQuery(document.body).trigger("fluentform_submission_success",{form:r,config:a,response:e}),"redirectUrl"in e.data.result)return e.data.result.message&&(t("<div/>",{id:x+"_success",class:"ff-message-success"}).html(e.data.result.message).insertAfter(r),r.find(".ff-el-is-error").removeClass("ff-el-is-error")),void(location.href=e.data.result.redirectUrl);t("<div/>",{id:x+"_success",class:"ff-message-success"}).html(e.data.result.message).insertAfter(r);var n=t("#"+x+"_success");n.length&&!h(n[0])&&t("html, body").delay(animDuration).animate({scrollTop:n.offset().top-(t("#wpadminbar")?32:0)-20},animDuration),r.find(".ff-el-is-error").removeClass("ff-el-is-error"),"hide_form"==e.data.result.action?r.hide().addClass("ff_force_hide"):r[0].reset()}})).fail((function(t){if(r.trigger("fluentform_submission_failed",{form:r,response:t}),t&&t.responseJSON&&t.responseJSON&&t.responseJSON.errors){if(g(t.responseJSON.errors),m(350),r.find(".fluentform-step").length){var n=r.find(".error").not(":empty:first").closest(".fluentform-step");if(n.length){var i=n.index();c(i,e.stepAnimationDuration,!1)}}}else g(t.responseText)})).always((function(e){if(r.find(".ff-btn-submit").removeClass("disabled").removeClass("ff-working").attr("disabled",!1),window.grecaptcha){var t=d(i.form_id);t&&grecaptcha.reset(t)}}))}catch(e){if(!(e instanceof ffValidationError))throw e;g(e.messages),m(350)}var _,b}(t(this))})),t(document).on("reset",k,(function(n){var i;i=t(this),t(".ff-step-body",r).length&&c(0,e.stepAnimationDuration),i.find(".ff-el-repeat .ff-t-cell").each((function(){t(this).find("input").not(":first").remove()})),i.find(".ff-el-repeat .ff-el-repeat-buttons-list").find(".ff-el-repeat-buttons").not(":first").remove(),i.find("input[type=file]").closest("div").find(".ff-uploaded-list").html("").end().closest("div").find(".ff-upload-progress").addClass("ff-hidden").find(".ff-el-progress-bar").css("width","0%"),t.each(a.conditionals,(function(e,r){t.each(r.conditions,(function(e,t){p(y(t.field))}))}))})))},d=function(e){var r;return t("form").has(".g-recaptcha").each((function(n,i){t(this).attr("data-form_id")==e&&(r=n)})),r},p=function(e){var r=e.prop("type");null!=r&&("checkbox"==r||"radio"==r?e.each((function(e,r){var n=t(this);n.prop("checked",n.prop("defaultChecked"))})):r.startsWith("select")?e.find("option").each((function(e,r){var n=t(this);n.prop("selected",n.prop("defaultSelected"))})):e.val(e.prop("defaultValue")),e.trigger("change"))},m=function(e){var n=a.settings.layout.errorMessagePlacement;if(n&&"stackToBottom"!=n){var i=r.find(".ff-el-is-error").first();i.length&&!h(i[0])&&t("html, body").delay(e).animate({scrollTop:i.offset().top-(t("#wpadminbar")?32:0)-20},e)}},h=function(e){if(!e)return!0;var r=e.getBoundingClientRect();return r.top>=0&&r.left>=0&&r.bottom<=t(window).height()&&r.right<=t(window).width()},g=function(e){if(r.parent().find(".ff-errors-in-stack").empty(),e)if("string"!=typeof e){var n=a.settings.layout.errorMessagePlacement;if(!n||"stackToBottom"==n)return _(e),!1;r.find(".error").empty(),r.find(".ff-el-group").removeClass("ff-el-is-error"),t.each(e,(function(e,r){"string"==typeof r&&(r=[r]),t.each(r,(function(t,r){b(e,r)}))}))}else _({error:[e]})},_=function(e){var r=s().parent().find(".ff-errors-in-stack");e&&(t.isEmptyObject(e)||(t.each(e,(function(e,n){"string"==typeof n&&(n=[n]),t.each(n,(function(n,i){var a=t("<div/>",{class:"error text-danger"}),o=t("<span/>",{class:"error-clear",html:"&times;"}),s=t("<span/>",{class:"error-text","data-name":y(e).attr("name"),html:i});a.append(s,o),r.append(a).show()}));var i=y(e);if(i){var a=i.attr("name"),o=t("[name='"+a+"']").first();o&&o.closest(".ff-el-group").addClass("ff-el-is-error")}})),h(r[0])||t("html, body").animate({scrollTop:r.offset().top-100},350),r.on("click",".error-clear",(function(){t(this).closest("div").remove(),r.hide()})).on("click",".error-text",(function(){var e=t("[name='".concat(t(this).data("name"),"']")).first();t("html, body").animate({scrollTop:e.offset()&&e.offset().top-100},350,(function(t){return e.focus()}))}))))},b=function(e,r){var n,i;(n=y(e)).length?(i=t("<div/>",{class:"error text-danger"}),n.closest(".ff-el-group").addClass("ff-el-is-error"),n.closest(".ff-el-input--content").find("div.error").remove(),n.closest(".ff-el-input--content").append(i.text(r))):_([r])},w=function(){var e=a.settings.layout.errorMessagePlacement;e&&"stackToBottom"!=e&&r.find(".ff-el-group,.ff_repeater_table").on("change","input,select,textarea",(function(){if(!window.ff_disable_error_clear){var e=t(this).closest(".ff-el-group");e.hasClass("ff-el-is-error")&&e.removeClass("ff-el-is-error").find(".error.text-danger").remove()}}))},y=function(e){var r=s(),n=t("[data-name='"+e+"']",r);return(n=n.length?n:t("[name='"+e+"']",r)).length?n:t("[name='"+e+"[]']",r)},{initFormHandlers:function(){u(),f(),w(),r.removeClass("ff-form-loading").addClass("ff-form-loaded"),r.on("show_element_error",(function(e,t){b(t.element,t.message)}))},registerFormSubmissionHandler:u,maybeInlineForm:f=function(){r.hasClass("ff-form-inline")&&r.find("button.ff-btn-submit").css("height","50px")},reinitExtras:function(){if(r.find(".ff-el-recaptcha.g-recaptcha").length){var e=r.find(".ff-el-recaptcha.g-recaptcha"),t=e.data("sitekey"),n=e.attr("id");grecaptcha.render(document.getElementById(n),{sitekey:t})}},initTriggers:function(){r=s(),jQuery(document.body).trigger("fluentform_init",[r,a]),jQuery(document.body).trigger("fluentform_init_"+a.id,[r,a]),r.find("input.ff-el-form-control").on("keypress",(function(e){return 13!==e.which})),r.data("is_initialized","yes"),r.find(".ff-el-tooltip").on("mouseenter",(function(e){var n=t(this).data("content"),i=t(".ff-el-pop-content");i.length||(t("<div/>",{class:"ff-el-pop-content"}).appendTo(document.body),i=t(".ff-el-pop-content")),i.html(n);var a=r.innerWidth()-20;i.css("max-width",a);var o=t(this).offset().left,s=r.offset().left,f=i.outerWidth(),c=i.outerHeight(),l=o-f/2+10;l+f>a?l=(s+a)/2:l<s&&(l=s),i.css("top",t(this).offset().top-c-5),i.css("left",l)})),r.find(".ff-el-tooltip").on("mouseleave",(function(){t(".ff-el-pop-content").remove()}))},validate:v=function(e){e.length||(e=t(".frm-fluent-form").find(":input").not(":button").filter((function(e,r){return!t(r).closest(".has-conditions").hasClass("ff_excluded")}))),e.each((function(e,r){t(r).closest(".ff-el-group").removeClass("ff-el-is-error").find(".error").remove()})),o().validate(e,a.rules)},showErrorMessages:g,scrollToFirstError:m,settings:a,formSelector:k}}console.log("No Fluent form JS vars found!")};var r={init:function(){this.initMultiSelect(),this.initMask(),this.initNumericFormat(),this.initCheckableActive()},initMultiSelect:function(){t.isFunction(window.Choices)&&t(".ff_has_multi_select").length&&t(".ff_has_multi_select").each((function(e,r){var i=n(n({},{removeItemButton:!0,silent:!0,shouldSort:!1,searchEnabled:!0,searchResultLimit:50}),window.fluentFormVars.choice_js_vars),a=t(r).attr("data-max_selected_options");parseInt(a)&&(i.maxItemCount=parseInt(a),i.maxItemText=function(e){var t=window.fluentFormVars.choice_js_vars.maxItemTextLang;return t=t.replace("%%maxItemCount%%",e)}),i.callbackOnCreateTemplates=function(){t(this.passedElement.element);return{option:function(e){var t=Choices.defaults.templates.option.call(this,e);return e.customProperties&&(t.dataset.calc_value=e.customProperties),t}}},t(r).data("choicesjs",new Choices(r,i))}))},initMask:function(){if(null!=jQuery.fn.mask){var e={clearIfNotMatch:!1,translation:{"*":{pattern:/[0-9a-zA-Z]/},0:{pattern:/\d/},9:{pattern:/\d/,optional:!0},"#":{pattern:/\d/,recursive:!0},A:{pattern:/[a-zA-Z0-9]/},S:{pattern:/[a-zA-Z]/}}};t("input[data-mask]").each((function(r,n){var i=(n=t(n)).data("mask").mask,a=e;n.attr("data-mask-reverse")&&(a.reverse=!0),n.attr("data-clear-if-not-match")&&(a.clearIfNotMatch=!0),n.mask(i,a)}))}},initCheckableActive:function(){t(document).on("change",".ff-el-form-check input[type=radio]",(function(){t(this).is(":checked")&&(t(this).closest(".ff-el-input--content").find(".ff-el-form-check").removeClass("ff_item_selected"),t(this).closest(".ff-el-form-check").addClass("ff_item_selected"))})),t(document).on("change",".ff-el-form-check input[type=checkbox]",(function(){t(this).is(":checked")?t(this).closest(".ff-el-form-check").addClass("ff_item_selected"):t(this).closest(".ff-el-form-check").removeClass("ff_item_selected")}))},initNumericFormat:function(){var e=t(".frm-fluent-form .ff_numeric");t.each(e,(function(e,r){var n=t(r),i=JSON.parse(n.attr("data-formatter"));n.val()&&n.val(window.ff_helper.formatCurrency(n,n.val())),n.on("blur change",(function(){var e=currency(t(this).val(),i).format();t(this).val(e)}))}))}},i=function(){return new function(){this.errors={},this.validate=function(e,r){var n,i,a=this,o=!0;e.each((function(e,s){n=t(s),i=n.prop("name").replace("[]",""),"repeater_item"===n.data("type")&&(i=n.attr("data-name"),r[i]=r[n.data("error_index")]),r[i]&&t.each(r[i],(function(e,t){if(!(e in a))throw new Error("Method ["+e+"] doesn't exist in Validator.");a[e](n,t)||(o=!1,i in a.errors||(a.errors[i]={}),a.errors[i][e]=t.message)}))})),!o&&this.throwValidationException()},this.throwValidationException=function(){var e=new ffValidationError("Validation Error!");throw e.messages=this.errors,e},this.required=function(e,r){if(!r.value)return!0;var n=e.prop("type");if("checkbox"==n||"radio"==n)return e.parents(".ff-el-group").attr("data-name")&&!r.per_row?e.parents(".ff-el-group").find("input:checked").length:t('[name="'+e.prop("name")+'"]:checked').length;if(n.startsWith("select")){var i=e.find(":selected");return!(!i.length||!i.val().length)}return"file"==n?e.closest("div").find(".ff-uploaded-list").find(".ff-upload-preview[data-src]").length:String(t.trim(e.val())).length},this.url=function(e,t){var r=e.val();return!t.value||!r.length||new RegExp("^(http|https|ftp|ftps)://([a-zA-Z0-9.-]+(:[a-zA-Z0-9.&amp;%$-]+)*@)*((25[0-5]|2[0-4][0-9]|[0-1]{1}[0-9]{2}|[1-9]{1}[0-9]{1}|[1-9]).(25[0-5]|2[0-4][0-9]|[0-1]{1}[0-9]{2}|[1-9]{1}[0-9]{1}|[1-9]|0).(25[0-5]|2[0-4][0-9]|[0-1]{1}[0-9]{2}|[1-9]{1}[0-9]{1}|[1-9]|0).(25[0-5]|2[0-4][0-9]|[0-1]{1}[0-9]{2}|[1-9]{1}[0-9]{1}|[0-9])|([a-zA-Z0-9-]+.)*[a-zA-Z0-9-]+.(com|[a-zA-Z]{2,10}))(:[0-9]+)*(/($|[a-zA-Z0-9.,?'\\+&amp;%$#=~_-]+))*$").test(r)},this.email=function(e,t){var r=e.val();if(!t.value||!r.length)return!0;return/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(r.toLowerCase())},this.numeric=function(e,r){var n=window.ff_helper.numericVal(e);return n=n.toString(),!r.value||!n||t.isNumeric(n)},this.min=function(e,t){var r=window.ff_helper.numericVal(e);return r=r.toString(),!t.value||!r.length||(this.numeric(e,t)?Number(r)>=Number(t.value):void 0)},this.max=function(e,t){var r=window.ff_helper.numericVal(e);return r=r.toString(),!t.value||!r.length||(this.numeric(e,t)?Number(r)<=Number(t.value):void 0)},this.max_file_size=function(){return!0},this.max_file_count=function(){return!0},this.allowed_file_types=function(){return!0},this.allowed_image_types=function(){return!0},this.valid_phone_number=function(e,t){if(!e.val())return!0;if(void 0===window.intlTelInputGlobals)return!0;if(e&&e[0]){var r=window.intlTelInputGlobals.getInstance(e[0]);if(!r)return!0;if(e.hasClass("ff_el_with_extended_validation"))return!!r.isValidNumber()&&(e.val(r.getNumber()),!0);var n=r.getSelectedCountryData(),i=e.val();return!e.attr("data-original_val")&&i&&n&&n.dialCode&&(e.val("+"+n.dialCode+i),e.attr("data-original_val",i)),!0}}}},a=t(".frm-fluent-form");function o(e){var t=fluentFormApp(e);t&&(t.initFormHandlers(),t.initTriggers())}t.each(a,(function(e,r){o(t(r))})),t(document).on("ff_reinit",(function(e,n){var i=t(n);i.attr("data-ff_reinit","yes"),fluentFormApp(i).reinitExtras(),window.grecaptcha&&grecaptcha.reset(),o(i),r.init()})),r.init()}(window.fluentFormVars,jQuery)}))}});
1
+ !function(e){var t={};function r(n){if(t[n])return t[n].exports;var i=t[n]={i:n,l:!1,exports:{}};return e[n].call(i.exports,i,i.exports,r),i.l=!0,i.exports}r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)r.d(n,i,function(t){return e[t]}.bind(null,i));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="/",r(r.s=563)}({563:function(e,t,r){e.exports=r(564)},564:function(e,t){function r(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function n(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?r(Object(n),!0).forEach((function(t){i(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function i(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}jQuery(document).ready((function(){window.fluentFormrecaptchaSuccessCallback=function(e){if(window.innerWidth<768&&/iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream){var t=jQuery(".g-recaptcha").filter((function(t,r){return grecaptcha.getResponse(t)==e}));t.length&&jQuery("html, body").animate({scrollTop:t.first().offset().top-jQuery(window).height()/2},0)}},window.ffValidationError=function(){var e=function(){};return(e.prototype=Object.create(Error.prototype)).constructor=e,e}(),window.ff_helper={numericVal:function(e){if(e.hasClass("ff_numeric")){var t=JSON.parse(e.attr("data-formatter"));return currency(e.val(),t).value}return e.val()||0},formatCurrency:function(e,t){if(e.hasClass("ff_numeric")){var r=JSON.parse(e.attr("data-formatter"));return currency(t,r).format()}return t}},function(e,t){e||(e={}),e.stepAnimationDuration=parseInt(e.stepAnimationDuration),window.fluentFormApp=function(r){var n=r.attr("data-form_instance"),o=window["fluent_form_"+n];if(o){o.form_id_selector;var a,f,s,c,l,u,d,p,m,h,v,g,y,_,w="."+n;return a=i,f=function(){return t("body").find("form"+w)},c=function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"next";r.trigger("update_slider",{goBackToStep:e,animDuration:t,isScrollTop:n,actionType:i})},l=function(){"yes"!=r.attr("data-ff_reinit")&&(t(document).on("submit",w,(function(e){e.preventDefault(),function(e){try{var r=e.find(":input").filter((function(e,r){return!t(r).closest(".has-conditions").hasClass("ff_excluded")}));m(r)}catch(e){if(!(e instanceof ffValidationError))throw e;h(e.messages),d(350)}}(t(this))})),t(document).on("reset",w,(function(n){var i;i=t(this),t(".ff-step-body",r).length&&c(0,e.stepAnimationDuration),i.find(".ff-el-repeat .ff-t-cell").each((function(){t(this).find("input").not(":first").remove()})),i.find(".ff-el-repeat .ff-el-repeat-buttons-list").find(".ff-el-repeat-buttons").not(":first").remove(),i.find("input[type=file]").closest("div").find(".ff-uploaded-list").html("").end().closest("div").find(".ff-upload-progress").addClass("ff-hidden").find(".ff-el-progress-bar").css("width","0%"),t.each(o.conditionals,(function(e,r){t.each(r.conditions,(function(e,t){u(_(t.field))}))}))})))},u=function(e){var r=e.prop("type");null!=r&&("checkbox"==r||"radio"==r?e.each((function(e,r){var n=t(this);n.prop("checked",n.prop("defaultChecked"))})):r.startsWith("select")?e.find("option").each((function(e,r){var n=t(this);n.prop("selected",n.prop("defaultSelected"))})):e.val(e.prop("defaultValue")),e.trigger("change"))},d=function(e){var n=o.settings.layout.errorMessagePlacement;if(n&&"stackToBottom"!=n){var i=r.find(".ff-el-is-error").first();i.length&&!p(i[0])&&t("html, body").delay(e).animate({scrollTop:i.offset().top-(t("#wpadminbar")?32:0)-20},e)}},p=function(e){if(!e)return!0;var r=e.getBoundingClientRect();return r.top>=0&&r.left>=0&&r.bottom<=t(window).height()&&r.right<=t(window).width()},h=function(e){if(r.parent().find(".ff-errors-in-stack").empty(),e)if("string"!=typeof e){var n=o.settings.layout.errorMessagePlacement;if(!n||"stackToBottom"==n)return v(e),!1;r.find(".error").empty(),r.find(".ff-el-group").removeClass("ff-el-is-error"),t.each(e,(function(e,r){"string"==typeof r&&(r=[r]),t.each(r,(function(t,r){g(e,r)}))}))}else v({error:[e]})},v=function(e){var r=f().parent().find(".ff-errors-in-stack");e&&(t.isEmptyObject(e)||(t.each(e,(function(e,n){"string"==typeof n&&(n=[n]),t.each(n,(function(n,i){var o=t("<div/>",{class:"error text-danger"}),a=t("<span/>",{class:"error-clear",html:"&times;"}),f=t("<span/>",{class:"error-text","data-name":_(e).attr("name"),html:i});o.append(f,a),r.append(o).show()}));var i=_(e);if(i){var o=i.attr("name"),a=t("[name='"+o+"']").first();a&&a.closest(".ff-el-group").addClass("ff-el-is-error")}})),p(r[0])||t("html, body").animate({scrollTop:r.offset().top-100},350),r.on("click",".error-clear",(function(){t(this).closest("div").remove(),r.hide()})).on("click",".error-text",(function(){var e=t("[name='".concat(t(this).data("name"),"']")).first();t("html, body").animate({scrollTop:e.offset()&&e.offset().top-100},350,(function(t){return e.focus()}))}))))},g=function(e,r){var n,i;(n=_(e)).length?(i=t("<div/>",{class:"error text-danger"}),n.closest(".ff-el-group").addClass("ff-el-is-error"),n.closest(".ff-el-input--content").find("div.error").remove(),n.closest(".ff-el-input--content").append(i.text(r))):v([r])},y=function(){var e=o.settings.layout.errorMessagePlacement;e&&"stackToBottom"!=e&&r.find(".ff-el-group,.ff_repeater_table").on("change","input,select,textarea",(function(){if(!window.ff_disable_error_clear){var e=t(this).closest(".ff-el-group");e.hasClass("ff-el-is-error")&&e.removeClass("ff-el-is-error").find(".error.text-danger").remove()}}))},_=function(e){var r=f(),n=t("[data-name='"+e+"']",r);return(n=n.length?n:t("[name='"+e+"']",r)).length?n:t("[name='"+e+"[]']",r)},{initFormHandlers:function(){l(),s(),y(),r.removeClass("ff-form-loading").addClass("ff-form-loaded"),r.on("show_element_error",(function(e,t){g(t.element,t.message)}))},registerFormSubmissionHandler:l,maybeInlineForm:s=function(){r.hasClass("ff-form-inline")&&r.find("button.ff-btn-submit").css("height","50px")},reinitExtras:function(){if(r.find(".ff-el-recaptcha.g-recaptcha").length){var e=r.find(".ff-el-recaptcha.g-recaptcha"),t=e.data("sitekey"),n=e.attr("id");grecaptcha.render(document.getElementById(n),{sitekey:t})}},initTriggers:function(){r=f(),jQuery(document.body).trigger("fluentform_init",[r,o]),jQuery(document.body).trigger("fluentform_init_"+o.id,[r,o]),r.find("input.ff-el-form-control").on("keypress",(function(e){return 13!==e.which})),r.data("is_initialized","yes"),r.find(".ff-el-tooltip").on("mouseenter",(function(e){var n=t(this).data("content"),i=t(".ff-el-pop-content");i.length||(t("<div/>",{class:"ff-el-pop-content"}).appendTo(document.body),i=t(".ff-el-pop-content")),i.html(n);var o=r.innerWidth()-20;i.css("max-width",o);var a=t(this).offset().left,f=r.offset().left,s=i.outerWidth(),c=i.outerHeight(),l=a-s/2+10;l+s>o?l=(f+o)/2:l<f&&(l=f),i.css("top",t(this).offset().top-c-5),i.css("left",l)})),r.find(".ff-el-tooltip").on("mouseleave",(function(){t(".ff-el-pop-content").remove()}))},validate:m=function(e){e.length||(e=t(".frm-fluent-form").find(":input").not(":button").filter((function(e,r){return!t(r).closest(".has-conditions").hasClass("ff_excluded")}))),e.each((function(e,r){t(r).closest(".ff-el-group").removeClass("ff-el-is-error").find(".error").remove()})),a().validate(e,o.rules)},showErrorMessages:h,scrollToFirstError:d,settings:o,formSelector:w}}console.log("No Fluent form JS vars found!")};var r={init:function(){this.initMultiSelect(),this.initMask(),this.initNumericFormat(),this.initCheckableActive()},initMultiSelect:function(){t.isFunction(window.Choices)&&t(".ff_has_multi_select").length&&t(".ff_has_multi_select").each((function(e,r){var i=n(n({},{removeItemButton:!0,silent:!0,shouldSort:!1,searchEnabled:!0,searchResultLimit:50}),window.fluentFormVars.choice_js_vars),o=t(r).attr("data-max_selected_options");parseInt(o)&&(i.maxItemCount=parseInt(o),i.maxItemText=function(e){var t=window.fluentFormVars.choice_js_vars.maxItemTextLang;return t=t.replace("%%maxItemCount%%",e)}),i.callbackOnCreateTemplates=function(){t(this.passedElement.element);return{option:function(e){var t=Choices.defaults.templates.option.call(this,e);return e.customProperties&&(t.dataset.calc_value=e.customProperties),t}}},t(r).data("choicesjs",new Choices(r,i))}))},initMask:function(){if(null!=jQuery.fn.mask){var e={clearIfNotMatch:!1,translation:{"*":{pattern:/[0-9a-zA-Z]/},0:{pattern:/\d/},9:{pattern:/\d/,optional:!0},"#":{pattern:/\d/,recursive:!0},A:{pattern:/[a-zA-Z0-9]/},S:{pattern:/[a-zA-Z]/}}};t("input[data-mask]").each((function(r,n){var i=(n=t(n)).data("mask").mask,o=e;n.attr("data-mask-reverse")&&(o.reverse=!0),n.attr("data-clear-if-not-match")&&(o.clearIfNotMatch=!0),n.mask(i,o)}))}},initCheckableActive:function(){t(document).on("change",".ff-el-form-check input[type=radio]",(function(){t(this).is(":checked")&&(t(this).closest(".ff-el-input--content").find(".ff-el-form-check").removeClass("ff_item_selected"),t(this).closest(".ff-el-form-check").addClass("ff_item_selected"))})),t(document).on("change",".ff-el-form-check input[type=checkbox]",(function(){t(this).is(":checked")?t(this).closest(".ff-el-form-check").addClass("ff_item_selected"):t(this).closest(".ff-el-form-check").removeClass("ff_item_selected")}))},initNumericFormat:function(){var e=t(".frm-fluent-form .ff_numeric");t.each(e,(function(e,r){var n=t(r),i=JSON.parse(n.attr("data-formatter"));n.val()&&n.val(window.ff_helper.formatCurrency(n,n.val())),n.on("blur change",(function(){var e=currency(t(this).val(),i).format();t(this).val(e)}))}))}},i=function(){return new function(){this.errors={},this.validate=function(e,r){console.log(r);var n,i,o=this,a=!0;e.each((function(e,f){n=t(f),i=n.prop("name").replace("[]",""),"repeater_item"===n.data("type")&&(i=n.attr("data-name"),r[i]=r[n.data("error_index")]),r[i]&&t.each(r[i],(function(e,t){if(!(e in o))throw new Error("Method ["+e+"] doesn't exist in Validator.");o[e](n,t)||(a=!1,i in o.errors||(o.errors[i]={}),o.errors[i][e]=t.message)}))})),!a&&this.throwValidationException()},this.throwValidationException=function(){var e=new ffValidationError("Validation Error!");throw e.messages=this.errors,e},this.required=function(e,r){if(!r.value)return!0;var n=e.prop("type");if("checkbox"==n||"radio"==n)return e.parents(".ff-el-group").attr("data-name")&&!r.per_row?e.parents(".ff-el-group").find("input:checked").length:t('[name="'+e.prop("name")+'"]:checked').length;if(n.startsWith("select")){var i=e.find(":selected");return!(!i.length||!i.val().length)}return"file"==n?e.closest("div").find(".ff-uploaded-list").find(".ff-upload-preview[data-src]").length:String(t.trim(e.val())).length},this.url=function(e,t){var r=e.val();return!t.value||!r.length||new RegExp("^(http|https|ftp|ftps)://([a-zA-Z0-9.-]+(:[a-zA-Z0-9.&amp;%$-]+)*@)*((25[0-5]|2[0-4][0-9]|[0-1]{1}[0-9]{2}|[1-9]{1}[0-9]{1}|[1-9]).(25[0-5]|2[0-4][0-9]|[0-1]{1}[0-9]{2}|[1-9]{1}[0-9]{1}|[1-9]|0).(25[0-5]|2[0-4][0-9]|[0-1]{1}[0-9]{2}|[1-9]{1}[0-9]{1}|[1-9]|0).(25[0-5]|2[0-4][0-9]|[0-1]{1}[0-9]{2}|[1-9]{1}[0-9]{1}|[0-9])|([a-zA-Z0-9-]+.)*[a-zA-Z0-9-]+.(com|[a-zA-Z]{2,10}))(:[0-9]+)*(/($|[a-zA-Z0-9.,?'\\+&amp;%$#=~_-]+))*$").test(r)},this.email=function(e,t){var r=e.val();if(!t.value||!r.length)return!0;return/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(r.toLowerCase())},this.numeric=function(e,r){var n=window.ff_helper.numericVal(e);return n=n.toString(),!r.value||!n||t.isNumeric(n)},this.min=function(e,t){var r=window.ff_helper.numericVal(e);return r=r.toString(),!t.value||!r.length||(this.numeric(e,t)?Number(r)>=Number(t.value):void 0)},this.max=function(e,t){var r=window.ff_helper.numericVal(e);return r=r.toString(),!t.value||!r.length||(this.numeric(e,t)?Number(r)<=Number(t.value):void 0)},this.max_file_size=function(){return!0},this.max_file_count=function(){return!0},this.allowed_file_types=function(){return!0},this.allowed_image_types=function(){return!0},this.valid_phone_number=function(e,t){if(!e.val())return!0;if(void 0===window.intlTelInputGlobals)return!0;if(e&&e[0]){var r=window.intlTelInputGlobals.getInstance(e[0]);if(!r)return!0;if(e.hasClass("ff_el_with_extended_validation"))return!!r.isValidNumber()&&(e.val(r.getNumber()),!0);var n=r.getSelectedCountryData(),i=e.val();return!e.attr("data-original_val")&&i&&n&&n.dialCode&&(e.val("+"+n.dialCode+i),e.attr("data-original_val",i)),!0}}}},o=t(".frm-fluent-form");function a(e){var t=fluentFormApp(e);t&&(t.initFormHandlers(),t.initTriggers())}t.each(o,(function(e,r){a(t(r))})),t(document).on("ff_reinit",(function(e,n){var i=t(n);i.attr("data-ff_reinit","yes"),fluentFormApp(i).reinitExtras(),window.grecaptcha&&grecaptcha.reset(),a(i),r.init()})),r.init()}(window.fluentFormVars,jQuery)}))}});
readme.txt CHANGED
@@ -4,7 +4,7 @@ Tags: contact form, contact forms, wp forms, forms, form builder, contact form b
4
  Requires at least: 4.5
5
  Tested up to: 5.7.2
6
  Requires PHP: 5.6
7
- Stable tag: 3.6.72
8
  License: GPLv2 or later
9
  License URI: https://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -322,6 +322,10 @@ The entire source code is <a href="https://github.com/fluentform/fluentform">ava
322
 
323
  == Changelog ==
324
 
 
 
 
 
325
  = 3.6.72 (Date: May 22, 2021) =
326
  * Fixes Sanitize Data and Escaping on render for custom CSS and JS
327
  * Sub-Page Slug URL escaping issue fixed
4
  Requires at least: 4.5
5
  Tested up to: 5.7.2
6
  Requires PHP: 5.6
7
+ Stable tag: 3.6.73
8
  License: GPLv2 or later
9
  License URI: https://www.gnu.org/licenses/gpl-2.0.html
10
 
322
 
323
  == Changelog ==
324
 
325
+ = 3.6.73 (Date: May 27, 2021) =
326
+ * Hot Fix: Form hide issue fixed after submission
327
+ * A big update is coming soon
328
+
329
  = 3.6.72 (Date: May 22, 2021) =
330
  * Fixes Sanitize Data and Escaping on render for custom CSS and JS
331
  * Sub-Page Slug URL escaping issue fixed