// source --> https://www.mathieu-unzel.com/wp-content/plugins/WP_Estimation_Form/assets/js/lfb_form.min.js?ver=9.699 var lfb_lastStepID=0,lfb_lastSteps=new Array,lfb_plannedSteps,lfb_gmapService=!1,tld_selectionMode=!1,lfb_calendars=new Array,lfb_stripe;function wpe_getForm(e){var t=!1;return jQuery.each(wpe_forms,function(){this.formID==e&&(t=this)}),t}function lfb_onResize(){if(jQuery("#estimation_popup.wpe_fullscreen").css({minHeight:jQuery(window).height()}),jQuery(window).width()<=768){jQuery("#estimation_popup .lfb_stepDescription").each(function(){jQuery(this).css({top:jQuery(this).closest(".genSlide").find(".stepTitle").height()+60})}),jQuery("#estimation_popup .genContent ").each(function(){var e=0;0 .tooltip").remove(),jQuery("body > .tooltip").remove(),jQuery('#estimation_popup[data-form="'+r.formID+'"] > .tooltip').remove()));if(t&&i.addClass("action"),t||!i.is(".action")){if("zoom"!=r.imgIconStyle&&i.find("span.icon_select").animate({bottom:160,opacity:0},200),i.is(".checked")){if(!t||!i.data("required")){"zoom"==r.imgIconStyle?(i.delay(200).css("transition-delay","0.2s"),i.find("span.icon_select").css("transition-delay","0s")):i.css("transition-delay","0s");var o=220;"zoom"==r.imgIconStyle&&(o=0),i.delay(o).removeClass("checked"),"zoom"!=r.imgIconStyle?i.delay(220).find("span.icon_select").removeClass("fui-check").addClass("fui-cross"):i.find("span.icon_select").css("transition-delay","0s"),i.delay(400).css("transition-delay","0s"),i.find(".icon_quantity").delay(300).fadeOut(200)}}else if(i.css("transition-delay","0s"),0!=r.disableTipMobile&&wpe_is_touch_device()||e.is('[data-type="slider"]')||e.is(".lfb_button")||""!=r.imgTitlesStyle||e.b_tooltip("show"),"zoom"==r.imgIconStyle&&i.find("span.icon_select").css("transition-delay",".5s"),i.is('[type="checkbox"][data-checkboxstyle="checkbox"]')||i.delay(220).addClass("checked"),"zoom"!=r.imgIconStyle&&i.delay(220).find("span.icon_select").removeClass("fui-cross").addClass("fui-check"),0\r\n]?)(\r\n|\n\r|\r|\n)/g,"$1"+(t||void 0===t?"
":"
")+"$2")}function wpe_initForms(){jQuery.each(wpe_forms,function(){var p=this;p.price=0,p.priceSingle=0,p.priceMax=0,p.step=0,p.gFormDesignCheck=0,p.timer_gFormSubmit=null,p.timer_gFormDesign=null,p.animationsSpeed*=1e3,p.reductionResult=0,p.reduction=0,p.discountCode="",p.discountCodeDisplayed=!1,p.initialPrice=parseFloat(p.initialPrice),p.contactSent=0,p.gravitySent=!1,p.shineFxIndex=0,p.subscriptionText=jQuery('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"] #finalPrice span:eq(1)').html(),p.richtextsContent=new Array,p.emailSent=!1,p.autoStart=!1,p.urlVariables="",p.useRazorpay=!1,p.razorpayReady=!1,p.stripeToken="";for(var e=0;e"+jQuery(this).attr("data-tooltiptext")+"")}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"] [data-type="numberfield"]:not([value])').val(0);var o=p.formID;1==p.save_to_cart?p.save_to_cart=!0:p.save_to_cart=!1,1==p.save_to_cart_edd?p.save_to_cart_edd=!0:p.save_to_cart_edd=!1,0 .tooltip").remove(),jQuery("body > .tooltip").remove(),jQuery('#estimation_popup[data-form="'+p.formID+'"] > .tooltip').remove())}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"] #mainPanel .genSlide .genContent div.selectable span.icon_select.lfb_fxZoom').css({textShadow:"-2px 0px "+jQuery('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"] #mainPanel').css("background-color")}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"]').is(".wpe_popup")&&!jQuery('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"]').closest("#lfb_bootstraped").parent().is("body")&&jQuery('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"]').closest("#lfb_bootstraped").detach().appendTo("body"),jQuery('#estimation_popup[data-form="'+p.formID+'"]').is(".wpe_fullscreen")&&jQuery("html,body").css("overflow-y","hidden"),0'),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"]').find("a.btn-primary").mouseover(function(){0==p.shineFxIndex&&lfb_shineBtn(o,jQuery(this).find(".lfb_shineCanvas"))})),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"] .lfb_dropzone').each(function(){var e=null;0
'+e+"
").css({position:"absolute",top:-55,left:-20,opacity:1}).hide(),a=1;jQuery(this).is("[data-stepslider]")&&0 .colpick").fadeOut()},onChange:function(e,t,a,r,i){jQuery(r).val("#"+t),jQuery(r).prev(".lfb_colorPreview").css({backgroundColor:"#"+t})}})}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"]').find('.lfb_colorPreview[data-urltarget],input[type="text"][data-itemid]:not(.lfb_colorpicker)[data-urltarget],textarea[data-itemid][data-urltarget],select[data-itemid][data-urltarget],input[type="number"][data-urltarget]').each(function(){jQuery(this).click(function(){if(!tld_selectionMode){var e=window.open(jQuery(this).attr("data-urltarget"),"_blank");"null"!=typeof e&&null!=e&&e.focus()}})}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"]').find('[data-autocomplete="1"]').each(function(){var e={};"city"==jQuery(this).attr("data-fieldtype")?e.types=["(cities)"]:"address"==jQuery(this).attr("data-fieldtype")?0s)&&jQuery(this).val("")}})});var n=wpe_forms[0].dateFormat;n=n.replace(/\\\//g,"/");var d=new Array;jQuery('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"] #mainPanel .genSlide .lfb_datepicker').each(function(){var e=new Date;if(jQuery(this).is('[data-allowpast="1"]')||jQuery(this).is('[data-datetype="time"]'))e=null;else if(jQuery(this).is('[data-allowpast="0"]')&&0 a').click(function(){tld_selectionMode||("less"==jQuery(this).attr("data-btn")?wpe_quantity_less:wpe_quantity_more)(this,o)}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"] .linkPrevious').click(function(){tld_selectionMode||wpe_previousStep(o)}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"] .btn-next').click(function(){tld_selectionMode||wpe_nextStep(o)}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"] #btnOrderPaypal').click(function(){tld_selectionMode||wpe_order(o)}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"] #finalSlide [data-toggle="switch"]').change(function(){wpe_toggleField(jQuery(this).attr("data-fieldid"),o)});var t=!1;jQuery(".gform_wrapper").each(function(){jQuery(this).attr("id").substr(jQuery(this).attr("id").lastIndexOf("_")+1,jQuery(this).attr("id").length)==p.gravityFormID&&(t?jQuery(this).remove():(t=!0,jQuery(this).detach().insertAfter('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"] #finalPrice')))}),setTimeout(function(){if(1parseInt(jQuery(this).attr("max"))&&jQuery(this).val(jQuery(this).attr("max")),wpe_updatePrice(p.formID),wpe_updateSummary(p.formID)}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"] input[type="number"][data-itemid]').keydown(function(e){return 69!=e.keyCode}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"] input[type="number"][data-itemid]').on("focusin",function(){0==jQuery(this).val()&&jQuery(this).val("")}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+p.formID+'"] input[type="number"][data-itemid]').focusout(function(){""==jQuery(this).val()&&jQuery(this).val(0),0==jQuery(this).val()&&!jQuery(this).is('[data-required="true"]')||(-1parseFloat(jQuery(this).attr("max"))&&jQuery(this).val(jQuery(this).attr("max")),""!=jQuery(this).val()&&!isNaN(parseInt(jQuery(this).val()))||jQuery(this).val(0),""!=jQuery(this).val()&&(jQuery(this).is('[data-valueasqt="0"]')||0
'+e+"
").css({position:"absolute",top:-55,left:-20,opacity:1}).hide(),t=1;jQuery(this).closest(".quantityBtns").is("[data-stepslider]")&&0'),jQuery("#gform_wrapper_"+a.gravityFormID+' .gform_wrapper label[for="'+jQuery(this).attr("id")+'"]').parent("li").next().is("br")||jQuery("#gform_wrapper_"+a.gravityFormID+' .gform_wrapper label[for="'+jQuery(this).attr("id")+'"]').parent("li").after("
"),jQuery(this).is(":checked")&&jQuery(this).trigger("click")}),jQuery("#gform_wrapper_"+a.gravityFormID+' .gform_wrapper input[type="checkbox"]:not(.ready)').each(function(){jQuery(this).addClass("ready");jQuery("#gform_wrapper_"+a.gravityFormID+' .gform_wrapper label[for="'+jQuery(this).attr("id")+'"]').html();jQuery("#gform_wrapper_"+a.gravityFormID+' .gform_wrapper label[for="'+jQuery(this).attr("id")+'"]').parent("li").css("display","inline-block"),jQuery("#gform_wrapper_"+a.gravityFormID+' .gform_wrapper label[for="'+jQuery(this).attr("id")+'"]').append(jQuery(this)),jQuery("#gform_wrapper_"+a.gravityFormID+' .gform_wrapper label[for="'+jQuery(this).attr("id")+'"]').addClass("checkbox"),jQuery(this).before(''),jQuery("#gform_wrapper_"+a.gravityFormID+' .gform_wrapper label[for="'+jQuery(this).attr("id")+'"]').parent("li").next().is("br")||jQuery("#gform_wrapper_"+a.gravityFormID+' .gform_wrapper label[for="'+jQuery(this).attr("id")+'"]').parent("li").after("
")}),jQuery("#gform_wrapper_"+a.gravityFormID+" .gform_wrapper label.checkbox").each(function(){0').parent().bootstrapSwitch(),jQuery('#estimation_popup.wpe_bootstraped [data-toggle="switch"][data-checkboxstyle="switch"]').on("change",function(){jQuery(this).is(":checked")||jQuery(this).removeClass("checked")}),jQuery("#estimation_popup.wpe_bootstraped input[type=checkbox][data-urltarget]").each(function(){jQuery(this).closest(".switch.has-switch").click(function(){if(!tld_selectionMode&&0

"+$panel.data("title")+" :


",y+="\n\n---------"+$panel.data("title")+" :---------\n",$panel.find(".itemBloc:not(.lfb_disabled)").each(function(){var e=jQuery(this),t=!0;if(0",y+=" - "+r+jQuery(a).data("originaltitle")+" : "+o+"\n")):t&&(_+=" - "+r+jQuery(a).data("originaltitle")+"
",y+=" - "+r+jQuery(a).data("originaltitle")+"\n");var p=parseFloat(jQuery(a).data("resprice"));isNaN(p)&&(p=parseFloat(jQuery(a).data("price")));var s=!1;if(jQuery(a).is('[data-singleprice="true"]')&&(s=!0),-1==jQuery.inArray(jQuery(a).attr("data-itemid"),h)){h.push(jQuery(a).attr("data-itemid"));var n=jQuery(a).attr("data-title");jQuery(a).is("[data-original-title]")&&jQuery(a).is("[data-reducqt]")&&(n=jQuery(a).attr("data-original-title")),jQuery(a).is("[data-originaltitle]")&&jQuery(a).is('[data-showprice="1"]')&&(n=jQuery(a).attr("data-originaltitle")),jQuery(a).is("[data-originallabel]")&&(n=jQuery(a).attr("data-originallabel")),b.push({label:n,itemid:jQuery(a).attr("data-itemid"),price:p,quantity:i,step:$panel.attr("data-title"),stepid:j,showInSummary:t,isSinglePrice:s})}}if(0",y+=" - "+d+" : "+o+"\n")}else{d=jQuery(a).attr("data-originaltitle");jQuery(a).is("select")&&(d+=" : "+jQuery(a).val()),t&&(_+=" - "+d+"
",y+=" - "+d+"\n")}n=jQuery(a).attr("data-title");jQuery(a).is("[data-originaltitle]")&&jQuery(a).is('[data-showprice="1"]')&&(n=jQuery(a).attr("data-originaltitle")),jQuery(a).is("[data-originallabel]")&&(n=jQuery(a).attr("data-originallabel")),jQuery(a).is("select")&&(n+=" : "+jQuery(a).val());s=!1;jQuery(a).is('[data-singleprice="true"]')&&(s=!0),-1==jQuery.inArray(jQuery(a).attr("data-itemid"),h)&&(h.push(jQuery(a).attr("data-itemid")),b.push({label:n,itemid:jQuery(a).attr("data-itemid"),price:parseFloat(jQuery(a).data("resprice")),quantity:1,step:$panel.attr("data-title"),stepid:j,showInSummary:t,isSinglePrice:s}))}if(0",y+=" - "+d+" : "+o+"\n")}else{d=jQuery(a).attr("data-originaltitle");jQuery(a).is("select")&&(d+=" : "+jQuery(a).val()),t&&(_+=" - "+d+"
",y+=" - "+d+"\n")}n=jQuery(a).attr("data-title");jQuery(a).is("[data-originaltitle]")&&jQuery(a).is('[data-showprice="1"]')&&(n=jQuery(a).attr("data-originaltitle")),jQuery(a).is("[data-originallabel]")&&(n=jQuery(a).attr("data-originallabel")),jQuery(a).is("select")&&(n+=" : "+jQuery(a).val());s=!1;jQuery(a).is('[data-singleprice="true"]')&&(s=!0),-1==jQuery.inArray(jQuery(a).attr("data-itemid"),h)&&(h.push(jQuery(a).attr("data-itemid")),b.push({label:n,itemid:jQuery(a).attr("data-itemid"),price:parseFloat(jQuery(a).data("resprice")),quantity:1,step:$panel.attr("data-title"),stepid:j,showInSummary:t,isSinglePrice:s}))}if(e.is(".lfb_richtext")&&!e.is(".lfb_shortcode")){a=e.get(0);!$panel.is('[data-showstepsum="0"]')&&jQuery(a).is('[data-showinsummary="true"]')||(t=!1),t&&b.push({label:jQuery(a).attr("data-title"),itemid:jQuery(a).attr("data-itemid"),value:jQuery(a).html(),step:$panel.attr("data-title"),stepid:j,showInSummary:t})}if(0",y+=" - "+r+d+" : "+o+"\n")}else{d=jQuery(a).attr("data-originaltitle");jQuery(a).is("select")&&(d+=" : "+jQuery(a).val()),t&&(_+=" - "+d+"
",y+=" - "+d+"\n")}n=jQuery(a).attr("data-title");jQuery(a).is("[data-originaltitle]")&&jQuery(a).is('[data-showprice="1"]')&&(n=jQuery(a).attr("data-originaltitle")),jQuery(a).is("[data-originallabel]")&&(n=jQuery(a).attr("data-originallabel")),jQuery(a).is("select")&&(n+=" : "+jQuery(a).val());s=!1;jQuery(a).is('[data-singleprice="true"]')&&(s=!0),-1==jQuery.inArray(jQuery(a).attr("data-itemid"),h)&&(h.push(jQuery(a).attr("data-itemid")),b.push({label:n,itemid:jQuery(a).attr("data-itemid"),price:parseFloat(jQuery(a).data("resprice")),quantity:parseFloat(jQuery(a).slider("value")),step:$panel.attr("data-title"),stepid:j,showInSummary:t,isSinglePrice:s}))}if(0",y+=" - "+d+" : "+o+"\n")}else{d=jQuery(a).attr("data-originaltitle");jQuery(a).is("select")&&(d+=" : "+jQuery(a).val()),t&&(_+=" - "+d+"
",y+=" - "+d+"\n")}n=jQuery(a).attr("data-title");jQuery(a).is("[data-originallabel]")&&(n=jQuery(a).attr("data-originallabel"));s=!1;jQuery(a).is('[data-singleprice="true"]')&&(s=!0),-1==jQuery.inArray(jQuery(a).attr("data-itemid"),h)&&(h.push(jQuery(a).attr("data-itemid")),b.push({label:n,itemid:jQuery(a).attr("data-itemid"),price:parseFloat(jQuery(a).data("resprice")),value:jQuery(a).val(),quantity:1,step:$panel.attr("data-title"),stepid:j,showInSummary:t,isSinglePrice:s}))}if(0'+jQuery(a).data("originaltitle")+" : "+jQuery(a).val().replace(/ /g,"_")+"
",y+=" - "+jQuery(a).data("originaltitle")+" : "+jQuery(a).val().replace(/ /g,"_")+"\n"),!$panel.is('[data-showstepsum="0"]')&&jQuery(a).is('[data-showinsummary="true"]')||(t=!1);n=jQuery(a).data("title");jQuery(a).is("[data-originallabel]")&&(n=jQuery(a).attr("data-originallabel")),-1==jQuery.inArray(jQuery(a).attr("data-itemid"),h)&&(h.push(jQuery(a).attr("data-itemid")),b.push({label:n,itemid:jQuery(a).attr("data-itemid"),value:jQuery(a).val(),step:$panel.attr("data-title"),stepid:j,showInSummary:t,isFile:!0}))}if(0
",u+=" - "+jQuery(this).attr("data-file").replace(/ /g,"_")+"\n"}),t&&(_+=' - '+jQuery(a).data("originaltitle")+" : "+l+"
",y+=" - "+jQuery(a).data("originaltitle")+" : "+u+"\n\n");n=jQuery(a).data("title");jQuery(a).is("[data-originallabel]")&&(n=jQuery(a).attr("data-originallabel")),-1==jQuery.inArray(jQuery(a).attr("data-itemid"),h)&&(h.push(jQuery(a).attr("data-itemid")),b.push({label:n,itemid:jQuery(a).attr("data-itemid"),value:l,step:$panel.attr("data-title"),stepid:j,showInSummary:t,isFile:!0}))}if(0"+jQuery(a).val()+"
",y+=" - "+jQuery(a).data("title")+" : "+jQuery(a).val()+" \n");n=jQuery(a).data("title");jQuery(a).is("[data-originallabel]")&&(n=jQuery(a).attr("data-originallabel")),-1==jQuery.inArray(jQuery(a).attr("data-itemid"),h)&&(h.push(jQuery(a).attr("data-itemid")),b.push({label:n,itemid:jQuery(a).attr("data-itemid"),value:jQuery(a).val(),step:$panel.attr("data-title"),stepid:j,showInSummary:t}))}if(0"+jQuery(a).val()+"
",y+=" - "+jQuery(a).data("title")+" : "+jQuery(a).val()+" \n");var m=jQuery(a).val(),f=void 0;p=void 0;jQuery(a).is('[data-valueasqt="1"]')&&(m=void 0,f=jQuery(a).val(),p=parseFloat(jQuery(a).data("resprice")),isNaN(p)&&(p=parseFloat(jQuery(a).data("price"))));s=!1;jQuery(a).is('[data-singleprice="true"]')&&(s=!0);n=jQuery(a).data("title");jQuery(a).is("[data-originallabel]")&&(n=jQuery(a).attr("data-originallabel")),-1==jQuery.inArray(jQuery(a).attr("data-itemid"),h)&&(h.push(jQuery(a).attr("data-itemid")),b.push({label:n,itemid:jQuery(a).attr("data-itemid"),value:m,quantity:f,price:p,step:$panel.attr("data-title"),stepid:j,showInSummary:t,isSinglePrice:s}))}if(0"+jQuery(a).next(".lfb_colorpicker").val()+"
",y+=" - "+jQuery(a).data("title")+" : "+jQuery(a).next(".lfb_colorpicker").val()+" \n");n=jQuery(a).data("title");jQuery(a).is("[data-originallabel]")&&(n=jQuery(a).attr("data-originallabel")),-1==jQuery.inArray(jQuery(a).attr("data-itemid"),h)&&(h.push(jQuery(a).attr("data-itemid")),b.push({label:n,itemid:jQuery(a).attr("data-itemid"),value:jQuery(a).next(".lfb_colorpicker").val(),step:$panel.attr("data-title"),stepid:j,showInSummary:t}))}if(0"+jQuery(a).val()+"
",y+=" - "+jQuery(a).data("title")+" : "+jQuery(a).val()+" \n");n=jQuery(a).data("title");jQuery(a).is("[data-originallabel]")&&(n=jQuery(a).attr("data-originallabel")),-1==jQuery.inArray(jQuery(a).attr("data-itemid"),h)&&(h.push(jQuery(a).attr("data-itemid")),b.push({label:n,itemid:jQuery(a).attr("data-itemid"),value:wpe_nl2br(jQuery(a).val()),step:$panel.attr("data-title"),stepid:j,showInSummary:t}))}})}}(!c.price||c.price<0)&&(c.price=0);if(/^\d+(\.\d{2})?$/.test(c.price)||(c.price=parseFloat(c.price).toFixed(2)),""!=c.discountCode)if(0 Coupon : "+c.discountCode+" ("+s+")"}else _+="
Coupon : "+c.discountCode;return"left"==c.currencyPosition?(r+=c.currency+wpe_formatPrice(parseFloat(c.price).toFixed(2),e),y+="\n\nTotal : "+c.currency+wpe_formatPrice(parseFloat(c.price).toFixed(2),e)):(r+=wpe_formatPrice(parseFloat(c.price).toFixed(2),e)+c.currency,y+="\n\nTotal : "+wpe_formatPrice(parseFloat(c.price).toFixed(2),e)+c.currency),new Array(_,r,b,y)}function wpe_check_gform_response(e){var t=wpe_getForm(e);if(0'),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #wtmt_paypalForm').append(''),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #wtmt_paypalForm').append('')),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #wtmt_paypalForm [name=a1]').val(r),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #wtmt_paypalForm [name=p1]').val(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #wtmt_paypalForm [name=p3]').val())}else jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #wtmt_paypalForm [name=a1]').remove(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #wtmt_paypalForm [name=t1]').remove(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #wtmt_paypalForm [name=p1]').remove();jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #wtmt_paypalForm [name=amount]').val(a),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #wtmt_paypalForm [name=a3]').val(a),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #wtmt_paypalForm [name=item_number]').val(t.current_ref),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #wtmt_paypalForm [name=item_name]').val(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #wtmt_paypalForm [name=item_name]').val()+" - "+t.current_ref),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #wtmt_paypalForm [type="submit"]').trigger("click")}else jQuery("#finalText").html(jQuery("#gform_wrapper_"+t.gravityFormID+" .gforms_confirmation_message").html()),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #finalSlide #gforms_confirmation_message').fadeIn(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #finalSlide #lfb_summary').fadeOut(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #finalSlide #lfb_couponContainer').fadeOut(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #finalSlide #lfb_legalNoticeContent').fadeOut(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #finalSlide .linkPrevious').fadeOut(),wpe_finalStep(e)}function wpe_quantity_less(e,t){var a=jQuery(e).parent().parent().find(".icon_quantity"),r=parseFloat(jQuery(e).parent().data("min")),i=parseInt(a.html());1 tr > th:eq(1)').is(".lfb-hidden")&&(a.find("table thead > tr > th:eq(1)").remove(),a.find("table tbody td.lfb_valueTd").remove()),a.find("th.sfb_summaryStep").attr("align","center"),a.find("table").attr("width","90%"),a.find("table").css("width","90%"),a.find("table").attr("border","1"),a.find("table").attr("bordercolor",lfb_rgb2hex(a.find("table").css("border-color"))),a.find("table").attr("style","width:90%;margin:0 auto;"),a.find("thead td, thead th").each(function(){jQuery(this).attr("bgcolor",lfb_rgb2hex(a.find("thead").css("background-color"))),jQuery(this).css("background",lfb_rgb2hex(a.find("thead").css("background-color")))}),a.find("th").each(function(){jQuery(this).attr("bgcolor",lfb_rgb2hex(jQuery(this).css("background-color")))}),a.find("td,th").each(function(){jQuery(this).attr("color",lfb_rgb2hex(jQuery(this).css("color"))),jQuery(this).html(''+jQuery(this).html()+"")}),a.find("table .lfb-hidden").remove(),a.find("table").attr("cellspacing","0"),a.find("table").attr("cellpadding","8"),a.find("table").attr("bgcolor","#FFFFFF"),a.find("td,th").each(function(){jQuery(this).attr("align",jQuery(this).css("text-align")),jQuery(this).css("padding",jQuery(this).css("padding"))}),"1"==form.summary_showAllPricesEmail&&(a.find(".sfb_summaryStep").attr("colspan",r),a.find("#lfb_summaryDiscountTr>th:eq(0),#sfb_summaryTotalTr>th:eq(0)").attr("colspan",r-1)),3==r?(a.find("td:not(:first-child)").each(function(){jQuery(this).attr("width","164")}),a.find("th:not(:first-child)").each(function(){jQuery(this).attr("width","164")}),a.find("tr>td:first-child").each(function(){jQuery(this).attr("width","340")}),a.find("tr>th:first-child").each(function(){jQuery(this).attr("width","340")})):(a.find("td:not(:first-child)").each(function(){jQuery(this).attr("width","103")}),a.find("th:not(:first-child)").each(function(){jQuery(this).attr("width","103")}),a.find("tr>td:first-child").each(function(){jQuery(this).attr("width","332")}),a.find("tr>th:first-child").each(function(){jQuery(this).attr("width","332")})),a.find("*:not(.lfb_value)").each(function(){var e=lfb_rgb2hex(jQuery(this).css("color"));jQuery(this).css({color:""}),jQuery(this).attr("style",jQuery(this).attr("style")+";color:"+e),0'+a.html()+""),a}function wpe_getContactInformations(e,t){if(t)var a={email:"",phone:"",firstName:"",lastName:"",address:"",city:"",state:"",zip:"",country:"",job:"",phoneJob:"",url:"",company:""};else(a=new Array).email="",a.phone="",a.firstName="",a.lastName="",a.address="",a.city="",a.state="",a.zip="",a.country="",a.job="",a.phoneJob="",a.url="",a.company="";jQuery('#estimation_popup.wpe_bootstraped[data-form="'+e+'"] [data-fieldtype="email"]').each(function(){0/g,"")).replace(/<\/span>/g,"")).substr(3,t.length),1==i.emailCustomerLinks&&(t="",e.find(".dz-success.dz-complete").each(function(){t+=jQuery(this).attr("data-url")+","}),0/gi,"\n"),t=escape(t)),o+="&"+a+"="+t}}}),0/g,"[n]");var i=d[1],o=d[2];n.urlVariables="",1==n.sendUrlVariables&&(n.urlVariables=lfb_getUrlVariables(s,d[2],!0)),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+s+'"]').is("[data-subs]")&&(i+=jQuery('#estimation_popup.wpe_bootstraped[data-form="'+s+'"]').attr("data-subs"));var p=0,l=!0;jQuery('#estimation_popup.wpe_bootstraped[data-form="'+s+'"] [data-activatePaypal="true"]:not(:checked):not(.checked)').each(function(){var e=jQuery(this).closest(".genSlide").attr("data-stepid");"final"!=e&&(e=parseInt(e)),-1==jQuery.inArray(e,lfb_lastSteps)||(l=!1)}),0'),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm').append(''),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm').append('')),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=a1]').val(i),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=p1]').val(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=p3]').val()),r<=0&&(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=cmd]').val("_xclick"),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=a3]').remove(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=t3]').remove(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=p3]').remove(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=bn]').remove(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=no_note]').remove(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=src]').remove(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=a1]').remove(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=t1]').remove(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=p1]').remove(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm').append(''))}else jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=a1]').remove(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=t1]').remove(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=p1]').remove(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=amount]').val(r);jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=return]').val(lfb_getRedirectionURL(s)),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=a3]').val(r),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=custom]').val(e),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=item_number]').val(e),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=item_name]').val(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [name=item_name]').val()+" - "+e),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+n.formID+'"] #wtmt_paypalForm [type="submit"]').trigger("click")}if(l&&0'+jQuery(this).val()+""+e+" "+jQuery(this).closest(".lfb_item").find("label").html()+"

":r+="

"+jQuery(this).closest(".lfb_item").find("label").html()+" "+e+' '+jQuery(this).val()+"

"}}),a=lfb_checkStepItemsValid("final",e),1==t.legalNoticeEnable&&(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #lfb_legalCheckbox').is(":checked")||(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #lfb_legalCheckbox').closest(".form-group").addClass("has-error"),a=!1)),1==a&&lfb_checkUserEmail(t)&&lfb_checkCaptcha(t,function(){jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #finalSlide').find("#wpe_btnOrder,.linkPrevious").fadeOut(250),wpe_uploadFiles(e,r,"",i)})}function wpe_previousStep(a){var r=wpe_getForm(a);navigator.userAgent.toLowerCase().match(/(iPad|iPhone|iPod)/i)&&(jQuery("#estimation_popup :not(.ui-slider-handle) > .tooltip").remove(),jQuery("body > .tooltip").remove(),jQuery('#estimation_popup[data-form="'+r.formID+'"] > .tooltip').remove()),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+r.formID+'"] .errorMsg').hide(),jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+a+'"] #mainPanel .genSlide[data-stepid="'+r.step+'"]').find("a.lfb_button.checked:not(.prechecked)").each(function(){wpe_itemClick(jQuery(this),!1,a)}),jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+a+'"] #mainPanel .genSlide[data-stepid="'+r.step+'"]').find("div.selectable.checked:not(.prechecked)").each(function(){wpe_itemClick(jQuery(this),!1,a)}),jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+a+'"] #mainPanel .genSlide[data-stepid="'+r.step+'"]').find('input[data-toggle="switch"]:checked:not(.prechecked)').each(function(){jQuery(this).trigger("click.auto")});var i=!1,o=0,p=0;jQuery.each(lfb_lastSteps,function(e){var t=this;parseInt(t)==parseInt(r.step)&&(i=!0),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+a+'"] #mainPanel .genSlide[data-stepid="'+t+'"] .lfb_executed').removeClass("lfb_executed"),i||(0 .tooltip").remove(),jQuery("body > .tooltip").remove(),jQuery('#estimation_popup[data-form="'+a.formID+'"] > .tooltip').remove()),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+a.formID+'"] .errorMsg').hide(),jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+t+'"] #mainPanel .genSlide[data-stepid="'+a.step+'"]').find("a.lfb_button.checked:not(.prechecked)").each(function(){wpe_itemClick(jQuery(this),!1,t)}),jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+t+'"] #mainPanel .genSlide[data-stepid="'+a.step+'"]').find("div.selectable.checked:not(.prechecked)").each(function(){wpe_itemClick(jQuery(this),!1,t)}),jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+t+'"] #mainPanel .genSlide[data-stepid="'+a.step+'"]').find('input[data-toggle="switch"]:checked:not(.prechecked)').each(function(){jQuery(this).trigger("click.auto")});var r=lfb_lastSteps.indexOf(e);lfb_lastSteps=jQuery.grep(lfb_lastSteps,function(e,t){if(t<=r)return e}),wpe_changeStep(e,t),setTimeout(function(){wpe_updateSummary(t,!0)},350),setTimeout(function(){wpe_updateStep(t)},2e3)}}function wpe_uploadFiles(s,n,e,d){var t=!0,l=wpe_getForm(s);if(l.useRazorpay&&!l.razorpayReady){t=!1;var a=l.price,r=0;jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l.formID+'"]').is('[data-isSubs="true"]')&&(r=l.price,(a=0)th:eq(0),#sfb_summaryTotalTr>th:eq(0)").attr("colspan",t.find("thead th:not(.lfb-hidden)").length-1),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+e+'"] #lfb_floatingSummary #lfb_floatingSummaryInner').html(t),t.find(".sfb_summaryStep").click(function(){lfb_returnToStep(parseInt(jQuery(this).attr("data-step")),e)}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+e+'"] #lfb_floatingSummary').is('[data-numberstep="1"]')&&t.find(".sfb_summaryStep").each(function(e){var t=e+1;jQuery(this).find("strong").html(t+". "+jQuery(this).find("strong").html())}))}}function wpe_updateSummary(l,e){var u=wpe_getForm(l);if(0'+e.step+""),m=e.stepid,isNaN(e.quantity)&&(e.quantity=1);var t="";isNaN(e.price)&&(t="lfb_noPriceRow",e.price=0);var a=e.value;void 0===e.value?a="":t+=" lfb_infoRow",""!=a&&e.showInSummary&&(f=!0);var r=e.price,i=wpe_formatPrice(e.quantity,l);if(""!=a&&0==r&&1==i)r=i="";else{var o=!1;parseFloat(r)<0&&(o=!0,r*=-1),r="left"==u.currencyPosition?u.currency+""+wpe_formatPrice(parseFloat(r).toFixed(2),l):wpe_formatPrice(parseFloat(r).toFixed(2),l)+""+u.currency,o&&(r="- "+r)}e.isFile;var p="";1==u.summary_hideQt&&(p="lfb-hidden"),1==u.summary_hideZero&&0==e.price&&(r=""),1==u.summary_hideZeroQt&&0==e.quantity&&(i="");var s="";e.showInSummary||(s="lfb-hidden"),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] [data-itemid="'+e.itemid+'"]').is('[data-hideqtsum="true"]')&&(i=""),0");var d=!0;jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] [data-itemid="'+e.itemid+'"]').is('[data-hidezeropricesum="true"]')&&0==e.price&&(d=!1),d&&(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] .lfb_itemContainer_'+e.itemid).is('[data-itemtype="filefield"]')?jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary table tbody #lfb_summaryDiscountTr').before(''+e.label+n+''+a+''+i+''+r+""):jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary table tbody #lfb_summaryDiscountTr').before(''+e.label+n+''+a+''+i+''+r+""))}}),0span').html(r),!u.discountCodeDisplayed){var i=jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary #lfb_summaryDiscountTr th[colspan]').html();0==jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary #lfb_summaryDiscountTr th[colspan] i').length&&(":"==i.substr(i.length-1,1)?jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary #lfb_summaryDiscountTr th[colspan]').html(i.substr(0,i.length-1)+" ("+u.discountCode+") :"):jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary #lfb_summaryDiscountTr th[colspan]').html(i+" ("+u.discountCode+")"))}jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary #lfb_summaryDiscountTr').slideDown(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_floatingSummary #lfb_summaryDiscountTr').slideDown()}(!u.price||u.price<0)&&(u.price=0),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary table tr th.sfb_summaryStep').each(function(){0==jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary table tr[data-itemstep="'+jQuery(this).attr("data-step")+'"]:not(.lfb-hidden)').length&&jQuery(this).parent().addClass("lfb-hidden")});var o=u.currency+""+wpe_formatPrice(parseFloat(u.price).toFixed(2),l);u.currency,wpe_formatPrice(parseFloat(u.priceSingle).toFixed(2),l);if("left"!=u.currencyPosition&&(o=wpe_formatPrice(parseFloat(u.price).toFixed(2),l)+""+u.currency,wpe_formatPrice(parseFloat(u.priceSingle).toFixed(2),l),u.currency),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary table #lfb_summaryTotal>span:eq(0)').html(o),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+u.formID+'"]').is("[data-totalrange]")&&0"+u.currency+wpe_formatPrice(d,l)+" "+s+" "+u.currency+wpe_formatPrice(_,l)+"","left"!=u.currencyPosition){n=parseInt(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+u.formID+'"]').attr("data-totalrange"));formatedPrice=p+" "+wpe_formatPrice(d,l)+u.currency+" "+s+" "+wpe_formatPrice(_,l)+u.currency+""}jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary table #lfb_summaryTotal>span:eq(0)').html(formatedPrice)}var y=4;1==u.summary_hideQt&&--y,1==u.summary_hidePrices&&--y,f?(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary table thead th:eq(1)').show().removeClass("lfb-hidden"),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary table tbody tr:eq(1)').show(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary table tbody td.lfb_valueTd').show()):(--y,jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary table td.lfb_valueTd').hide(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary table thead th:eq(1)').hide().addClass("lfb-hidden")),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary table tbody tr#sfb_summaryTotalTr th[colspan]').attr("colspan",y-1),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary table tbody tr#lfb_summaryDiscountTr th[colspan]').attr("colspan",y-1),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary table tbody tr th.sfb_summaryStep').attr("colspan",y)}jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"]').is('[data-sumstepsclick="1"]')&&jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"] #lfb_summary .sfb_summaryStep:not([data-step="final"])').each(function(){jQuery(this).css("cursor","pointer"),jQuery(this).click(function(){lfb_returnToStep(parseInt(jQuery(this).attr("data-step")),l)})}),wpe_updateFloatingSummary(l),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+l+'"]').trigger("summaryUpdated")}function wpe_changeStep(t,a){var r=wpe_getForm(a);if(jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+a+'"] #mainPanel').css("max-height",jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+a+'"] #mainPanel').height()),jQuery("#estimation_popup :not(.ui-slider-handle) > .tooltip").remove(),jQuery("body > .tooltip").remove(),jQuery('#estimation_popup[data-form="'+r.formID+'"] > .tooltip').remove(),jQuery('#estimation_popup[data-form="'+r.formID+'"] .datetimepicker ').hide(),0 .lfb_btnNextContainer').hide():(jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+a+'"] #mainPanel .genSlide[data-stepid="'+t+'"] .lfb_btnNextContainer').fadeIn(500),jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+a+'"] #mainPanel .genSlide[data-stepid="'+t+'"] .lfb_btnNextContainerStripe').hide(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+r.formID+'"] #lfb_paymentMethodBtns').hide(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+r.formID+'"] #lfb_stripeForm .lfb_stripeContainer').hide(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+r.formID+'"] #lfb_stripeForm .lfb_btnNextContainer').hide()):jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+a+'"] #mainPanel .genSlide[data-stepid="'+t+'"] .lfb_btnNextContainer').fadeIn(500),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+r.formID+'"]').is('[data-previousstepbtn="true"]')&&"final"==t?setTimeout(function(){var e=!1;jQuery('#estimation_popup.wpe_bootstraped[data-form="'+r.formID+'"] .genSlide[data-stepid="'+t+'"] ').find(".btn-next,#btnOrderPaypal,#lfb_btnPayStripe,#wpe_btnOrder,#btnOrderRazorpay").each(function(){"none"!=jQuery(this).css("display")&&"none"!=jQuery(this).closest(".lfb_btnNextContainer").css("display")&&(e=!0)}),e?jQuery('#estimation_popup.wpe_bootstraped[data-form="'+r.formID+'"] .genSlide[data-stepid="'+t+'"] ').find(".linkPrevious").css({marginTop:-15}):jQuery('#estimation_popup.wpe_bootstraped[data-form="'+r.formID+'"] .genSlide[data-stepid="'+t+'"] ').find(".linkPrevious").css({marginTop:24}),0 .tooltip").remove(),jQuery("body > .tooltip").remove(),jQuery('#estimation_popup[data-form="'+a+'"] > .tooltip').remove(),setTimeout(function(){},100),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+a+'"]').trigger("stepChanged"),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+a+'"]').attr("data-currentstep",t)},2*r.animationsSpeed+550),wpe_updatePrice(a),r.backFomFinal&&(r.backFomFinal=!1)},300)},d),jQuery("#estimation_popup :not(.ui-slider-handle) > .tooltip").remove(),jQuery("body > .tooltip").remove(),jQuery('#estimation_popup[data-form="'+a+'"] > .tooltip').remove(),wpe_updatePrice(a)}function wpe_findPotentialsSteps(i,o){var e=wpe_getForm(o),p=new Array,s=new Array,n=new Array,d=0;return jQuery.each(e.links,function(){var e=this;if(e.originID==i){var t=!1,a=!0;if(e.conditions&&"[]"!=e.conditions){e.conditionsO=JSON.parse(e.conditions);var r=lfb_checkConditions(e.conditionsO,o,i);t=r.error,a=r.errorOR}else n.push(e.destinationID),a=!1;("OR"==e.operator&&!a||"OR"!=e.operator&&!t)&&(e.conditionsO=JSON.parse(e.conditions),s.push({stepID:parseInt(e.destinationID),nbConditions:e.conditionsO.length}),e.conditionsO.length>d&&(d=e.conditionsO.length),p.push(parseInt(e.destinationID)))}}),0==i&&p.push(parseInt(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o+'"] #mainPanel .genSlide[data-start="1"]').attr("data-stepid"))),0==p.length?p.push("final"):0e.value&&(Q=!1);break;case"PriceInferior":s=parseFloat(a.data("resprice"));(a.is(".lfb_button:not(.checked)")||a.is(".selectable:not(.checked)")||a.is("input[type=checkbox]:not(:checked)")||s>=e.value)&&(j=!0),(a.is(".checked")||a.is(":checked"))&&se.value||parseInt(a.find(".wpe_qtfield").val())>e.value)&&(Q=!1):a.is('[data-type="slider"]')&&a.is(".ui-slider")&&parseInt(a.slider("value"))>e.value&&(Q=!1),a.is("input")&&(parseInt(a.val())<=e.value&&(j=!0),parseInt(a.val())>e.value&&(Q=!1));break;case"QtInferior":(a.is(".selectable:not(.checked)")||0=e.value||0=e.value||a.is('[data-type="slider"]')&&a.is(".ui-slider")&&parseInt(a.slider("value"))>=e.value)&&(j=!0),a.is(".selectable")?(a.is(".selectable.checked")&&parseInt(a.find(".icon_quantity").html())=e.value&&(j=!0),parseInt(a.val())e.value&&(Q=!1)):a.is('[data-datetype="time"]')?(moment.utc(a.datetimepicker("getDate")).format("HH:mm")<=e.value&&(j=!0),moment.utc(a.datetimepicker("getDate")).format("HH:mm")>e.value&&(Q=!1)):(moment.utc(a.datetimepicker("getDate")).isSameOrBefore(moment.utc(e.value).format("YYYY-MM-DD HH:mm"))&&(j=!0),moment.utc(a.datetimepicker("getDate")).isAfter(moment.utc(e.value).format("YYYY-MM-DD HH:mm"))&&(Q=!1));else if(a.is(".lfb_timepicker")){var n=parseInt(e.value.substr(0,e.value.indexOf(":"))),d=parseInt(e.value.substr(e.value.indexOf(":")+1,2));0parseFloat(e.value)&&(Q=!1));break;case"inferior":if(a.is(".lfb_datepicker"))a.is('[data-datetype="date"]')?(moment.utc(a.datetimepicker("getDate")).format("YYYY-MM-DD")>=e.value&&(j=!0),moment.utc(a.datetimepicker("getDate")).format("YYYY-MM-DD")=e.value&&(j=!0),moment.utc(a.datetimepicker("getDate")).format("HH:mm")=parseFloat(e.value)&&(j=!0),parseFloat(a.val())e.value&&(Q=!1);break;case"inferior":f>=e.value&&(j=!0),form.priceparseFloat(e.value)&&(Q=!1);break;case"inferior":parseFloat(form.price)>=parseFloat(e.value)&&(j=!0),parseFloat(form.price)e.value&&(Q=!1);break;case"inferior":f>=e.value&&(j=!0),fe.value&&(Q=!1);break;case"inferior":c>=e.value&&(j=!0),cparseInt(jQuery(this).attr("data-validmax"))&&(e=!0),jQuery(this).is("[data-validcar]")&&""!=jQuery(this).attr("data-validcar")){var t=jQuery(this);if(-1parseInt(jQuery(this).attr("data-maxfiles"))&&(o=!1,jQuery(this).parent().addClass("has-error"),p||lfb_scrollToItem(jQuery(this),r,i))}),jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+i+'"] #mainPanel .genSlide[data-stepid="'+r+'"]').find('textarea[data-required="true"]:not(.lfb_disabled)').each(function(){0==jQuery(this).closest("#lfb_stripeForm").length&&0==jQuery(this).closest("#wtmt_paypalForm").length&&jQuery(this).val().length<1&&(o=!1,jQuery(this).closest(".form-group").addClass("has-error"),p||lfb_scrollToItem(jQuery(this),r,i))}),jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+i+'"] #mainPanel .genSlide[data-stepid="'+r+'"]').find('input[type=checkbox][data-required="true"]:not(.lfb_disabled)').each(function(){jQuery(this).is(":checked")||(o=!1,jQuery(this).closest(".form-group,p,.itemBloc").addClass("has-error"),p||lfb_scrollToItem(jQuery(this),r,i))}),jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+i+'"] #mainPanel .genSlide[data-stepid="'+r+'"]').find('.selectable[data-required="true"]:not(.lfb_disabled)').each(function(){jQuery(this).is(".checked")||(o=!1,jQuery(this).find(".icon_select").addClass("lfb_error"),p||lfb_scrollToItem(jQuery(this),r,i))}),jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+i+'"] #mainPanel .genSlide[data-stepid="'+r+'"]').find('.lfb_button[data-required="true"]:not(.lfb_disabled)').each(function(){jQuery(this).is(".checked")||(o=!1,jQuery(this).find(".icon_select").addClass("lfb_error"),p||lfb_scrollToItem(jQuery(this),r,i))}),o}function wpe_nextStep(e){var t=wpe_getForm(e);jQuery("#lfb_bootstraped :not(.ui-slider-handle) > .tooltip").remove(),jQuery('#estimation_popup[data-form="'+t.formID+'"] > .tooltip').remove(),navigator.userAgent.toLowerCase().match(/(iPad|iPhone|iPod)/i)&&setTimeout(function(){jQuery("#lfb_bootstraped :not(.ui-slider-handle) > .tooltip").remove()},500),lfb_updateShowSteps(e),jQuery(".errorMsg").hide();var a=!0,r=!0,i=wpe_findPotentialsSteps(t.step,e);if(0 p').slideDown(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+e+'"] .lfb_btnFloatingSummary').css({display:"inline-block"}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+e+'"] .lfb_btnSaveForm').css({display:"inline-block"}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #btnStart').parent().fadeOut(t.animationsSpeed,function(){"2"!=t.showSteps&&jQuery('#estimation_popup.wpe_bootstraped[data-form="'+e+'"]').find(".genPrice,#lfb_stepper").fadeIn(t.animationsSpeed),t.autoStart||jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+t.formID+'"] #mainPanel').fadeIn(t.animationsSpeed+t.animationsSpeed/2,function(){wpe_nextStep(e)})})}function wpe_initListeners(i){var o=wpe_getForm(i);jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] #mainPanel .genSlide div.selectable .img, #estimation_popup.wpe_bootstraped[data-form="'+i+'"] #mainPanel .genSlide div.selectable .icon_select').click(function(){tld_selectionMode||wpe_itemClick(jQuery(this).parent(),!0,i)}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] #mainPanel .genSlide a.lfb_button').click(function(){tld_selectionMode||wpe_itemClick(jQuery(this),!0,i)}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] #mainPanel .genSlide [data-callnextstep="1"]').click(function(){!tld_selectionMode&&jQuery(this).is(".checked")&&wpe_nextStep(i)}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] #mainPanel input[type=checkbox][data-price]').change(function(){jQuery(this).is('[data-usedistance="true"]')&&lfb_removeDistanceError(jQuery(this).attr("data-itemid"),i),wpe_updatePrice(i,jQuery(this).attr("data-itemid"))}),jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+i+'"] #mainPanel input[type=checkbox][data-group]').change(function(e){var t=jQuery(this);t.is(":checked")&&(jQuery(this).closest(".genSlide").find('div.selectable.checked[data-group="'+t.data("group")+'"]').each(function(){wpe_itemClick(jQuery(this),!1,i)}),jQuery(this).closest(".genSlide").find('input[type=checkbox][data-group="'+t.data("group")+'"]:checked').each(function(){jQuery(this).is(t)||jQuery(this).trigger("click.auto")}),jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+i+'"]').is('[data-autoclick="1"]')&&0==t.closest(".genSlide").find("[data-itemid]").not('[data-group="'+t.data("group")+'"]').length&&wpe_nextStep(wpe_getForm(i).formID))}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] #mainPanel .genSlide select[data-itemid]').change(function(){var e=jQuery(this).val(),t=0;jQuery(this).find("option").each(function(){jQuery(this).attr("value")==e&&(t=jQuery(this).attr("data-price"))}),jQuery(this).attr("data-price",t),jQuery(this).data("price",t),wpe_updatePrice(i)}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] #mainPanel .genSlide select[data-itemid]').trigger("change"),jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"] #mainPanel input[type=checkbox][data-price]').change(function(){}),jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"] #mainPanel .genSlide input.wpe_qtfield').change(function(){wpe_updatePrice(i,jQuery(this).attr("data-itemid"))}),jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"] #mainPanel .genSlide').find("input[type=text][data-title],textarea[data-title],input[type=file][data-title],input[type=number][data-title]").change(function(){0');e.css({width:jQuery(this).get(0).width,height:jQuery(this).get(0).height}),jQuery(this).hide(),jQuery(this).after(e);var t=e.get(0).getContext("2d"),a=new Image;a.onload=function(){t.fillStyle=r.colorA,t.fillRect(0,0,e.get(0).width,e.get(0).height),t.fill(),t.globalCompositeOperation="destination-in",t.drawImage(a,0,0,e.get(0).width,e.get(0).height)},jQuery(this).is("[data-lazy-src]")?a.src=jQuery(this).attr("data-lazy-src"):a.src=jQuery(this).attr("src")}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+r.formID+'"] #mainPanel .genSlide div.selectable img[data-tint="false"]').each(function(){jQuery(this).is("[data-src]")&&jQuery(this).attr("src",jQuery(this).attr("data-src"))}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+r.formID+'"] #mainPanel .genSlide div.selectable.checked , #estimation_popup.wpe_bootstraped[data-form="'+r.formID+'"] #mainPanel .genSlide input[type=checkbox]:checked').hover(function(){jQuery(this).addClass("lfb_hover")},function(){jQuery(this).removeClass("lfb_hover")})}function lfb_getDistanceCalc(e,o,p,t,a,s){google.maps.UnitSystem.METRIC;if("route"==wpe_getForm(o).distancesMode)(lfb_gmapService=new google.maps.DistanceMatrixService).getDistanceMatrix({origins:[t],destinations:[a],travelMode:google.maps.TravelMode.DRIVING,unitSystem:google.maps.UnitSystem.METRIC,avoidHighways:!1,avoidTolls:!1},function(e,t){var a=!1;if(t==google.maps.DistanceMatrixStatus.OK){var r=0;e.rows[0].elements[0].distance?(r=e.rows[0].elements[0].distance.value,r/=1e3,"miles"==s&&(r*=.62)):a=!0;jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o+'"] [data-itemid="'+p+'"]');jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o+'"] [data-itemid="'+p+'"]').attr("data-distance",r),wpe_updateSummary(o),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o+'"] #lfb_summary table tr[data-itemstep="'+p+'"] td:eq(2)').html(r),wpe_updatePrice(o),lfb_removeDistanceError(p,o)}else a=!0;a&&lfb_showDistanceError(p,o)});else{var r=new google.maps.Geocoder;r.geocode({address:t},function(e,t){if(void 0!==e[0]){var i=e[0].geometry.location;r.geocode({address:a},function(e,t){if(void 0!==e[0]){var a=e[0].geometry.location,r=google.maps.geometry.spherical.computeDistanceBetween(i,a);r/=1e3,"miles"==s&&(r*=.62);jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o+'"] [data-itemid="'+p+'"]');jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o+'"] [data-itemid="'+p+'"]').attr("data-distance",r),wpe_updateSummary(o),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o+'"] #lfb_summary table tr[data-itemstep="'+p+'"] td:eq(2)').html(r),wpe_updatePrice(o),lfb_removeDistanceError(p,o)}else lfb_showDistanceError(p,o)})}else lfb_showDistanceError(p,o)})}return 0}function lfb_executeCalculation(calculation,formID,targetID){calculation=calculation.replace(/\\/g,"");var form=wpe_getForm(formID),price=0,i=0,elementsToReplace=new Array,$target=jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+targetID+'"]'),_stepID=parseInt($target.closest(".genSlide").attr("data-stepid"));for(calculation=calculation.replace(/\[variable\]/g,"[price]"),calculation=calculation.replace(/\[quantity\]/g,"[price]"),calculation=calculation.replace(/\[value\]/g,"[price]");-1!=(i=calculation.indexOf("variable-",i+1));){var variableID=calculation.substr(i+9,calculation.indexOf("]",i)-(i+9)),value=0,variable=lfb_getVariableByID(form,variableID);variable&&(value=variable.value),elementsToReplace.push({oldValue:calculation.substr(i-1,calculation.indexOf("]",i)+1-(i-1)),newValue:value})}for(;-1!=(i=calculation.indexOf("item-",i+1));){var itemID=calculation.substr(i+5,calculation.indexOf("_",i)-(i+5)),action=calculation.substr(calculation.indexOf("_",i)+1,calculation.indexOf("]",i)-1-calculation.indexOf("_",i)),value=0,$item=jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+itemID+'"]');"isChecked"==action&&(value=jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+itemID+'"]').is(".checked")||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+itemID+'"]').is(":checked")?"1==1":"1==0"),"isUnchecked"==action&&(value=jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+itemID+'"]').is(".checked")||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+itemID+'"]').is(":checked")?"1==0":"1==1"),"isFilled"==action&&(value=$item.is(".lfb_dropzone")?0<$item.find(".dz-preview[data-file].dz-success.dz-complete").length?"1==1":"1==0":0<$item.val().length?"1==1":"1==0"),"price"==action&&(value=0,"total"==itemID?value=form.price:(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+itemID+'"]').is(".checked")||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+itemID+'"]').is(":checked")||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+itemID+'"]').is("select")||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+itemID+'"]').is('[data-type="slider"]'))&&(value=parseFloat(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+itemID+'"]').data("resprice")),isNaN(value)&&(value=0))),"quantity"==action&&(value=0,$item.is(".lfb_disabled")||($item.is('input[type="number"]')||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+itemID+'"]').is(".checked")||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+itemID+'"]').is(":checked")?(value=0<$item.find(".icon_quantity").length?parseFloat($item.find(".icon_quantity").html()):$item.is('input[type="number"]')?$item.val():0<$item.find(".wpe_qtfield").length?$item.find(".wpe_qtfield").val():1,isNaN(value)&&(value=0)):jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+itemID+'"]').is('[data-type="slider"]')&&(value=jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+itemID+'"]').slider("value")))),"value"==action&&(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+itemID+'"]').is("select")||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+itemID+'"]').is('input:not([type="number"])')||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+itemID+'"]').is("textarea")?$item.is(".lfb_disabled")||(value="'"+jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+itemID+'"]').val()+"'"):(value=$item.is(".lfb_disabled")?0:parseFloat(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+formID+'"] #mainPanel .genSlide [data-itemid="'+itemID+'"]').val()),isNaN(value)&&(value=0))),"date"==action&&(value=$item.is(".lfb_datepicker")&&null!=$item.datetimepicker("getDate")?"'"+moment($item.datetimepicker("getDate")).format("YYYY-MM-DD")+"'":"null"),elementsToReplace.push({oldValue:calculation.substr(i-1,calculation.indexOf("]",i)+1-(i-1)),newValue:value})}for(;-1!=(i=calculation.indexOf("step-",i+1));){var stepID=calculation.substr(i+5,calculation.indexOf("_",i)-(i+5)),action=calculation.substr(calculation.indexOf("_",i)+1,calculation.indexOf("]",i)-1-calculation.indexOf("_",i));"quantity"==action&&(value=wpe_getStepQuantities(formID,stepID,targetID)),elementsToReplace.push({oldValue:calculation.substr(i-1,calculation.indexOf("]",i)+1-(i-1)),newValue:value})}var todayDate=new Date,month=todayDate.getMonth()+1;month<10&&(month="0"+month);var today=todayDate.getFullYear().toString()+month.toString()+todayDate.getDate().toString();if(calculation=calculation.replace(/\[currentDate\]/g,today),-1

'+a.txtDistanceError+"

");var i=jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t+'"] [data-itemid="'+e+'"]').closest(".genSlide").attr("data-stepid");"final"!=a.step||a.backFomFinal||(a.backFomFinal=!0,wpe_changeStep(i,t)),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+t+'"]').trigger("lfb_distanceError")}function wpe_updateLabelItem(e,t){form=wpe_getForm(t),e.is(".dropzone")||e.closest(".itemBloc").find("label").each(function(){-1"+form.currency+wpe_formatPrice(n,d)+"
"+p+"
"+form.currency+wpe_formatPrice(_,d)+""}else jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price').removeClass("lfb_notNull");if("left"!=form.currencyPosition)if(i=wpe_formatPrice(form.price,d)+""+form.currency,r=wpe_formatPrice(form.priceSingle,d)+""+form.currency,jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"]').is("[data-totalrange]")&&0"+wpe_formatPrice(n,d)+form.currency+"
"+p+"
"+wpe_formatPrice(_,d)+form.currency+""}else jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price').removeClass("lfb_notNull");if(1==form.showTotalBottom&&(u&&0span.lfb_subPrice').remove(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .lfb_totalBottom>br').remove()):(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .lfb_totalBottom').addClass("lfb_priceSingle"),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .lfb_totalBottom').each(function(){0==jQuery(this).find(".lfb_subPrice").length&&jQuery(this).find(">span:eq(0)").after('
+ '+i+"")})):(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .lfb_totalBottom').removeClass("lfb_priceSingle"),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .lfb_totalBottom>span.lfb_subPrice').remove(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .lfb_totalBottom>br').remove()),u&&0 span:first-child').html(r),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .lfb_totalBottom> span.lfb_subPrice').hide(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .lfb_totalBottom> span:eq(2)').hide(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .lfb_totalBottom .lfb_subTxtBottom').hide()):(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .lfb_totalBottom> span.lfb_subPrice').show(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .lfb_totalBottom> span:eq(2)').show(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .lfb_totalBottom> span:first-child').html(r),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .lfb_totalBottom> span.lfb_subPrice').html("+ "+i),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .lfb_totalBottom .lfb_subTxtBottom').show()):(form.price<=0?jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .lfb_totalBottom .lfb_subTxtBottom').hide():jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .lfb_totalBottom .lfb_subTxtBottom').show(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .lfb_totalBottom> span:first-child').html(i))),0==form.showSteps){u&&0span.lfb_subPrice').remove()):(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price').addClass("lfb_priceSingle"),0==jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price> span.lfb_subPrice').length&&jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price>span:eq(0)').after('+ '+i+"")):(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price').removeClass("lfb_priceSingle"),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price>span.lfb_subPrice').remove()),u&&0 span:first-child').css("top","6px"),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price> span:first-child').html(r),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price> span.lfb_subPrice').hide(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price> span:eq(2)').hide()):(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price> span:first-child').css("top","-5px"),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price> span.lfb_subPrice').show(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price> span:eq(2)').show(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price> span:first-child').html(r),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price> span.lfb_subPrice').html("+ "+i)):(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"]').is('[data-isSubs="true"]')?jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price> span:first-child').css("position","relative").css("top","6px"):jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price> span:first-child').css("position","relative").css("top","0px"),0 span:first-child').css("position","relative").css("top","0px"),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price> span:eq(1)').show()):jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price> span:eq(1)').hide(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price> span:first-child').html(i)),0 span:first-child').length&&(8 span:first-child').html().length?16<=parseInt(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price').css("font-size"))&&jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price').css("font-size","16px"):jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price').css("font-size","18px"),9 span:first-child').html().length&&14<=parseInt(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price').css("font-size"))&&jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price').css("font-size","14px"),10 span:first-child').html().length&&11<=parseInt(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price').css("font-size"))&&jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] .genPrice .progress .progress-bar-price').css("font-size","11px"));var y=form.price;jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"]').is('[data-isSubs="true"]')&&"single"==form.progressBarPriceType&&(y=form.priceSingle);var b=100*y/form.priceMax;1==form.showInitialPrice&&(b=100*(y-parseFloat(form.initialPrice))/form.priceMax),100span:eq(0)').html(h),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"]').is("[data-totalrange]")&&0"+form.currency+wpe_formatPrice(n,d)+"
"+p+"
"+form.currency+wpe_formatPrice(_,d)+"","left"!=form.currencyPosition){s=parseInt(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"]').attr("data-totalrange"));i=o+"
"+wpe_formatPrice(n,d)+form.currency+"
"+p+"
"+wpe_formatPrice(_,d)+form.currency+""}jQuery('#estimation_popup.wpe_bootstraped[data-form="'+d+'"] #lfb_summary table #lfb_summaryTotal>span:eq(0)').html(i.replace(//g," "))}wpe_updateSummary(d),u&&0span:eq(0)').html(""+j+"")):(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] #finalPrice span:eq(2)').css("display","inline-block"),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] #finalPrice span:eq(1)').html("+"+i+form.subscriptionText),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] #finalPrice span:eq(1)').css("display","block"),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+d+'"] #lfb_summary table #lfb_summaryTotal>span:eq(0)').html(""+j+"
+"+h))):0==form.priceSingle&&0==form.price?(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] #finalPrice span:eq(1)').css("display","none"),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] #finalPrice span:eq(2)').css("display","none"),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] #finalPrice span:eq(0)').html(i),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+form.formID+'"] #finalPrice span:eq(1)').html(form.subscriptionText)):0==form.priceSingle&&0 span:first-child').html(r+"/"+t),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .genPrice .progress .progress-bar').css("width",p+"%")}else if(3==a.showSteps){jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] #lfb_stepper *:not(#lfb_stepperBar)').remove();e=!1,o=new Array;jQuery.each(lfb_plannedSteps,function(){e||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] #mainPanel .genSlide[data-stepid="'+this+'"]').is(".lfb_disabled")||!(0');jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] #lfb_stepper').append(a),a.b_tooltip({html:!0,container:'#estimation_popup[data-form="'+i+'"]',placement:"bottom"}),s?a.addClass("lfb_disabledPoint"):parseInt(this)==n?(a.addClass("lfb_currentPoint"),s=!0):a.on("click",function(){lfb_returnToStep(parseInt(jQuery(this).attr("data-stepid")),i)});var r=100/o.length*e;100!=r&&0!=r||1!=o.length?r+=100/o.length/2:r=50,a.css({left:r+"%"}),parseInt(this)==n&&jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] #lfb_stepper #lfb_stepperBar').css({width:r+"%"})}),"final"==a.step&&jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] #lfb_stepper #lfb_stepperBar').css({width:"100%"})}}function wpe_initPanelResize(e){wpe_getForm(e);jQuery(window).resize(function(){lfb_resize(e)})}function lfb_resize(e){var t=jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+e+'"] #mainPanel .genSlide[data-stepid="'+form.step+'"] .stepTitle').height(),a=jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+e+'"] #mainPanel .genSlide[data-stepid="'+form.step+'"] .genContent').outerHeight()+parseInt(jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+e+'"] #mainPanel').css("padding-bottom"))+102+t;"final"==form.step&&(a-=80),jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+e+'"] #mainPanel').animate({minHeight:a})}function lfb_rgb2hex(t){if(!(-1 p').slideDown()}function lfb_initRichTextValues(e){jQuery('#estimation_popup.wpe_bootstraped[data-form="'+e+'"] .lfb_richtext[data-itemid]:not(.lfb_shortcode)').each(function(){var e=0,t=new Array;parseInt(jQuery(this).closest(".genSlide").attr("data-stepid"));if(void 0!==form.richtextsContent[jQuery(this).attr("data-itemid").toString()]){for(var a=form.richtextsContent[jQuery(this).attr("data-itemid").toString()];-1!=(e=a.indexOf("[variable-",e+1));){var r='';t.push({oldValue:a.substr(e,a.indexOf("]",e)+1-e),newValue:r})}for(e=0;-1!=(e=a.indexOf("item-",e+1));){r='';t.push({oldValue:a.substr(e-1,a.indexOf("]",e)+1-(e-1)),newValue:r})}if(-1';t.push({oldValue:a.substr(e-1,a.indexOf("]",e)+1-(e-1)),newValue:r})}if(-1';t.push({oldValue:a.substr(e-1,a.indexOf("]",e)+1-(e-1)),newValue:r})}var g=new Date,w=g.getMonth()+1;w<10&&(w="0"+w);g.getFullYear().toString(),w.toString(),g.getDate().toString();var v=wpe_forms[0].dateFormat.toUpperCase();v=(v=(v=v.replace(/\\\//g,"/")).replace(/d /g,"DD ")).replace(/yyyy/g,"YYYY"),a=(a=(a=a.replace(/\[currentDate\]/g,moment(g).format(v))).replace(/\[total\]/g,'')).replace(/\[total_quantity\]/g,''),jQuery.each(t,function(){a=a.replace(this.oldValue,this.newValue)}),jQuery(this).html(a)}})}function lfb_updateRichTextValues(v){var I=wpe_getForm(v),D=new Date,e=D.getMonth()+1;e<10&&(e="0"+e);var S=D.getFullYear().toString()+e.toString()+D.getDate().toString();jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] .genSlide[data-stepid="'+I.step+'"] .lfb_richtext[data-itemid]:not(.lfb_shortcode) .lfb_richVariable[data-varvariableid]').each(function(){var e=jQuery(this).attr("data-varvariableid"),t=lfb_getVariableByID(I,e),a=0;t&&(a=t.value),jQuery(this).html(a)}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] .genSlide[data-stepid="'+I.step+'"] .lfb_richtext[data-itemid]:not(.lfb_shortcode) .lfb_richVariable:not([data-varvariableid])').each(function(){var e=parseInt(jQuery(this).closest(".genSlide").attr("data-stepid")),t=jQuery(this).closest(".lfb_richtext").attr("data-itemid"),a=jQuery(this).attr("data-varitemid"),r=jQuery(this).attr("data-action"),i=0,o=jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] #mainPanel .genSlide [data-itemid="'+a+'"]');if("price"==r&&(i=0,"total"==a?i=I.price:(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] #mainPanel .genSlide [data-itemid="'+a+'"]').is(".checked")||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] #mainPanel .genSlide [data-itemid="'+a+'"]').is(":checked")||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] #mainPanel .genSlide [data-itemid="'+a+'"]').is("select")||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] #mainPanel .genSlide [data-itemid="'+a+'"]').is('[data-type="slider"]'))&&(i=parseFloat(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] #mainPanel .genSlide [data-itemid="'+a+'"]').data("resprice")),isNaN(i)&&(i=0)),i=wpe_formatPrice(parseFloat(i),v),"left"==I.currencyPosition?i=I.currency+i:i+=I.currency),"title"!=r&&"label"!=r||(i=o.is(".lfb_disabled")?"":jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] #mainPanel .genSlide [data-itemid="'+a+'"]').is(".checked")||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] #mainPanel .genSlide [data-itemid="'+a+'"]').is(":checked")||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] #mainPanel .genSlide [data-itemid="'+a+'"]').is("select")||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] #mainPanel .genSlide [data-itemid="'+a+'"]').is('[type="text"]')||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] #mainPanel .genSlide [data-itemid="'+a+'"]').is('[type="number"]')||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] #mainPanel .genSlide [data-itemid="'+a+'"]').is("textarea")||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] #mainPanel .genSlide [data-itemid="'+a+'"]').is(".lfb_colorPreview")||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] #mainPanel .genSlide [data-itemid="'+a+'"]').is("lfb_layeredImage")||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] #mainPanel .genSlide [data-itemid="'+a+'"]').is('[data-type="slider"]')||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] #mainPanel .genSlide [data-itemid="'+a+'"]').is(".lfb_dropzone")||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] #mainPanel .genSlide [data-itemid="'+a+'"]').is('[data-type="slider"]')?o.attr("data-originallabel"):""),"quantity"==r&&(o.is("input")||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] #mainPanel .genSlide [data-itemid="'+a+'"]').is(".checked")||jQuery('#estimation_popup.wpe_bootstraped[data-form="'+v+'"] #mainPanel .genSlide [data-itemid="'+a+'"]').is(":checked")?(i=o.is("input")?o.val():0',"")).replace(" ","")).replace("","")).replace("
",""),size:12345,accepted:!0,kind:"image"};t.emit("addedfile",r),t.files.push(r),t.createThumbnailFromUrl(r,o.imgPreview,function(){t.emit("complete",r)},"anonymous")}}else $item.is('[data-type="numberfield"]')?0!=e&&($item.is('[data-valueasqt="1"]')?$item.val(e.quantity):$item.val(e.value)):$item.is("select")?0!=e&&$item.val(e.value):$item.is('[data-type="slider"]')?0!=e&&$item.slider("value",parseInt(e.quantity)):$item.is("textarea")?0!=e&&$item.val(e.value):$item.is('input[type="text"]')&&0!=e&&$item.val(e.value)}),e!=a?lfb_lastSteps.push(parseInt(e)):(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] [data-stepid="'+e+'"] .errorMsg').hide(),"1"==o.intro_enabled?(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] #startInfos > p').slideDown(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnFloatingSummary').css({display:"inline-block"}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnSaveForm').css({display:"inline-block"}),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"] #btnStart').parent().fadeOut(o.animationsSpeed,function(){"2"!=o.showSteps&&jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"]').find(".genPrice,#lfb_stepper").fadeIn(o.animationsSpeed),jQuery(' #estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"] #mainPanel').fadeIn(o.animationsSpeed+o.animationsSpeed/2,function(){wpe_changeStep(a,i)})})):wpe_changeStep(a,i))})),setTimeout(function(){jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"] .genSlide.lfb_activeStep').css("opacity",1)},2e3)}else localStorage.removeItem("lfb_formsession"),localStorage.removeItem("lfb_savedFormID"),localStorage.removeItem("lfb_savedForm"),localStorage.removeItem("lfb_savedFormPastSteps"),localStorage.removeItem("lfb_savedFormStep"),localStorage.removeItem("lfb_savedFormTime"),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnSaveForm').children(".fa").attr("class","fa "+jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnSaveForm').attr("data-originalicon")),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnSaveForm').children(".fab").attr("class","fab "+jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnSaveForm').attr("data-originalicon")),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnSaveForm').children(".fas").attr("class","fas "+jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnSaveForm').attr("data-originalicon")),""!=jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnSaveForm').attr("data-defaulttext")&&jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnSaveForm span:not(.fas):not(.fab):not(.fa)').html(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnSaveForm').attr("data-defaulttext"));else jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnSaveForm').children(".fa").attr("class","fa "+jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnSaveForm').attr("data-originalicon")),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnSaveForm').children(".fab").attr("class","fab "+jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnSaveForm').attr("data-originalicon")),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnSaveForm').children(".fas").attr("class","fas "+jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnSaveForm').attr("data-originalicon")),""!=jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnSaveForm').attr("data-defaulttext")&&jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnSaveForm span:not(.fas):not(.fab):not(.fa)').html(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+i+'"] .lfb_btnSaveForm').attr("data-defaulttext"))}function lfb_getCalendarByID(e){var t=!1;return jQuery.each(lfb_calendars,function(){this.id==e&&(t=this)}),t}function lfb_getDisabledHours(e,r,a,i){var o=new Array,t=lfb_getCalendarByID(e);if(0!=t){if(""!=jQuery('#estimation_popup .lfb_datepicker[data-calendarid="'+t.id+'"][data-hoursdisabled]').attr("data-hoursdisabled")){var p=jQuery('#estimation_popup .lfb_datepicker[data-calendarid="'+t.id+'"]').attr("data-hoursdisabled");-1=e.format("mm")&&5*t=e.format("mm")&&5*t&&-1==jQuery.inArray(5*t,p)&&p.push(parseInt(5*t));if(moment.utc(this.endDate).format("YYYY-MM-DD")==r&&moment.utc(this.endDate).format("HH")==i&&e.format("hh")!=moment.utc(this.endDate).format("hh"))for(t=0;t<=11;t++)5*t=_datepicker.attr("data-maxevents")&&p.push(a);for(var r=1;r<=t.diff(e,"days");r++){var i=e.add(r,"days");lfb_getCalendarEventsAtDate(s,i)>=_datepicker.attr("data-maxevents")&&p.push(i.format("YYYY-MM-DD"))}}else{e=moment.utc(this.startDate),_datepicker.attr("data-eventdurationtype");"mins"==_datepicker.attr("data-eventdurationtype")&&0,this.startDate=e.format("YYYY-MM-DD HH:mm");t=moment.utc(this.endDate),a=e.format("YYYY-MM-DD");if(1";jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"]').find('#lfb_stripeModal [data-info="amount"]').html(e)}else if("fixed"==o.payMode){e=""+lfb_formatPriceWithCurrency(a=parseFloat(o.fixedToPay),o.formID)+"";jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"]').find('#lfb_stripeModal [data-info="amount"]').html(e)}jQuery.ajax({url:o.ajaxurl,type:"post",data:{action:"lfb_getStripePaymentIntent",singleTotal:a,subTotal:r,formID:o.formID,customerInfos:wpe_getContactInformations(o.formID,!0)},success:function(e){e=JSON.parse(e),o.stripeToken=e.token,o.stripeCustomerID=e.customerID;var t=lfb_stripe.elements();cardElement=t.create("card"),cardElement.mount("#lfb_stripe_card-element"),cardElement.addEventListener("change",function(e){e.error?jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"] #lfb_stripe_card-error').html(e.error.message):jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"] #lfb_stripe_card-error').html("")}),o.cardElement=cardElement,jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"]').find("#lfb_stripeModal [data-panel]").hide(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"]').find('#lfb_stripeModal [data-panel="form"]').show(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"]').find("#lfb_stripeModal .modal-footer").slideDown()}})}else{var i=lfb_stripe.elements();cardElement=i.create("card"),cardElement.mount("#lfb_stripe_card-element"),cardElement.addEventListener("change",function(e){e.error?jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"] #lfb_stripe_card-error').html(e.error.message):jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"] #lfb_stripe_card-error').html("")}),o.cardElement=cardElement;a=parseFloat(o.price),r=0;if(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"]').is('[data-isSubs="true"]')&&(a=parseFloat(o.priceSingle),r=parseFloat(o.price)),"percent"==o.payMode){e=""+lfb_formatPriceWithCurrency(a=parseFloat(a)*(parseFloat(o.percentToPay)/100),o.formID)+"";jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"]').find('#lfb_stripeModal [data-info="amount"]').html(e)}else if("fixed"==o.payMode){e=""+lfb_formatPriceWithCurrency(a=parseFloat(o.fixedToPay),o.formID)+"";jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"]').find('#lfb_stripeModal [data-info="amount"]').html(e)}jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"]').find("#lfb_stripeModal [data-panel]").hide(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"]').find('#lfb_stripeModal [data-panel="form"]').show(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"]').find("#lfb_stripeModal .modal-footer").slideDown()}jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"] #lfb_stripeModal a[data-action="pay"]').unbind("click"),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"] #lfb_stripeModal a[data-action="pay"]').click(function(){var e=!1;jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"] #lfb_stripeModal .has-error').removeClass("has-error"),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"] #lfb_stripeModal [name="ownerName"]').val().length<3&&(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"] #lfb_stripeModal [name="ownerName"]').closest(".form-group").addClass("has-error"),e=!0),e||(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"]').find("#lfb_stripeModal [data-panel]").hide(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"]').find('#lfb_stripeModal [data-panel="loading"]').show(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"]').find("#lfb_stripeModal .modal-footer").hide(),lfb_stripe.createSource(o.cardElement).then(function(e){e.error?(jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"] [data-info="error"]').html(e.error.message),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"]').find("#lfb_stripeModal [data-panel]").hide(),jQuery('#estimation_popup.wpe_bootstraped[data-form="'+o.formID+'"]').find('#lfb_stripeModal [data-panel="fail"]').show()):(o.stripeSrc=e.source.id,0