PluginProbe
Bit Form – Contact Form, Payment Forms, Multi Step Forms, Calculator & Custom Form Builder / V3.3.2
Bit Form – Contact Form, Payment Forms, Multi Step Forms, Calculator & Custom Form Builder vV3.3.2
V3.3.2 3.3.1 V-3.3.0 3.2.2 3.2.1 3.2.0 3.1.4 3.1.3 3.1.2 3.1.1 3.1.0 V3.0.3 V3.0.2 -3.0.1 V_3.0.0 1.1.1 1.1.8 1.2 1.3 1.4 1.4.18 1.5.2 1.9 2.0 2.10.0 All 139 releases
bit-form / assets / bf-854-219.js

bf-854-219.js in Bit Form – Contact Form, Payment Forms, Multi Step Forms, Calculator & Custom Form Builder V3.3.2, at assets/bf-854-219.js

2 lines 7.1 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 import{a as R,g as V,i as Y,u as k,m as z,H as G,j as r,_ as g,f as M,aY as y,bI as $,eo as J,b1 as O}from"./main-96.js";import{F as m}from"./bf-460-326.js";import{E as b}from"./bf-765-167.js";import{S as Q}from"./bf-283-176.js";import"./bf-721-323.js";import"./bf-200-43.js";import"./bf-781-46.js";import"./bf-431-60.js";/* empty css */import"./bf-63-62.js";import"./bf-762-63.js";import"./bf-285-324.js";import"./bf-245-208.js";import"./bf-870-206.js";import"./bf-550-57.js";import"./bf-621-177.js";import"./bf-163-182.js";import"./bf-405-178.js";import"./bf-678-179.js";import"./bf-542-181.js";import"./bf-687-180.js";import"./bf-403-183.js";import"./bf-235-184.js";import"./bf-235-185.js";import"./bf-551-68.js";import"./bf-890-186.js";import"./bf-682-187.js";import"./bf-825-45.js";import"./bf-894-52.js";import"./bf-580-188.js";import"./bf-20-55.js";import"./bf-135-189.js";import"./bf-377-190.js";import"./bf-624-191.js";import"./bf-859-210.js";import"./bf-178-325.js";import"./bf-994-212.js";import"./bf-828-327.js";import"./bf-29-328.js";function Be(){var T,j,N,L,F,H,W,_;const{css:p}=R(),{fieldKey:i}=V(),[c,f]=Y(O),C=k(z);if(!i)return null;const e=G(c[i]),w=e.adminLbl||"",E=((T=e.valid)==null?void 0:T.minlength)||"",S=((j=e.valid)==null?void 0:j.maxlength)||"",B=((N=e.valid)==null?void 0:N.maxword)||"",I=((L=e.valid)==null?void 0:L.minword)||"",v=C.err||{},x=l=>{var a,n,d,s;const t=[];(a=l.valid)!=null&&a.minlength&&t.push("Minimum ${field.minlength} character required."),(n=l.valid)!=null&&n.maxlength&&t.push("${field.value_length} of ${field.maxlength} Max Characters."),(d=l.valid)!=null&&d.minword&&t.push("Minimum ${field.minword} word required."),(s=l.valid)!=null&&s.maxword&&t.push("${field.value_wordlength} of ${field.maxword} Max Word."),t.length>0&&(l.helperTxt=t.join(" "),l.hlpTxtHide=!0,J(i,"hlpTxt"))},q=l=>{var n,d,s,o,h;const t=l.target.value;t===""?((n=e.valid)!=null&&n.minlength&&delete e.valid.minlength,(d=e.err)!=null&&d.minlength&&delete e.err.minlength,!((s=e.valid)!=null&&s.maxlength)&&!((o=e.valid)!=null&&o.maxword)&&!((h=e.valid)!=null&&h.minword)&&e.helperTxt.includes("${field.minlength}")?(delete e.helperTxt,delete e.hlpTxtHide):x(e)):(e.valid||(e.valid={}),e.valid.minlength=t,e.err||(e.err={}),e.err.minlength||(e.err.minlength={}),e.err.minlength.dflt=v.minlength||`<p style="margin:0">Minimum ${t} character required.</p>`,e.err.minlength.show=!0,x(e));const a=M(c,u=>{u[i]=e});f(a),y(i),$({event:`Min length updated to ${t}: ${e.lbl||w||i}`,type:"set_minlength",state:{fields:a,fldKey:i}})},A=l=>{var n,d,s,o,h;const t=l.target.value;t===""?((n=e.valid)!=null&&n.maxlength&&delete e.valid.maxlength,(d=e.err)!=null&&d.maxlength&&delete e.err.maxlength,!((s=e.valid)!=null&&s.minlength)&&!((o=e.valid)!=null&&o.maxword)&&!((h=e.valid)!=null&&h.minword)?(delete e.helperTxt,delete e.hlpTxtHide):x(e)):(e.valid||(e.valid={}),e.valid.maxlength=t,e.err||(e.err={}),e.err.maxlength||(e.err.maxlength={}),e.err.maxlength.dflt=v.maxlength||`<p style="margin:0">Maximum ${t} character allowed.</p>`,e.err.maxlength.show=!0,x(e));const a=M(c,u=>{u[i]=e});f(a),y(i),$({event:`Max length updated to ${t}: ${e.lbl||w||i}`,type:"set_maxlength",state:{fields:a,fldKey:i}})},K=l=>{var n,d,s,o,h;const t=l.target.value;t===""?((n=e.valid)!=null&&n.maxword&&delete e.valid.maxword,(d=e.err)!=null&&d.maxword&&delete e.err.maxword,!((s=e.valid)!=null&&s.minlength)&&!((o=e.valid)!=null&&o.maxlength)&&!((h=e.valid)!=null&&h.minword)?(delete e.helperTxt,delete e.hlpTxtHide):x(e)):(e.valid||(e.valid={}),e.valid.maxword=t,e.err||(e.err={}),e.err.maxword||(e.err.maxword={}),e.err.maxword.dflt=v.maxword||`<p style="margin:0">Maximum ${t} word allowed.</p>`,e.err.maxword.show=!0,x(e));const a=M(c,u=>{u[i]=e});f(a),y(i),$({event:`Max word updated to ${t}: ${e.lbl||w||i}`,type:"set_maxword",state:{fields:a,fldKey:i}})},P=l=>{var n,d,s,o,h;const t=l.target.value;t===""?((n=e.valid)!=null&&n.minword&&delete e.valid.minword,(d=e.err)!=null&&d.minword&&delete e.err.minword,!((s=e.valid)!=null&&s.minlength)&&!((o=e.valid)!=null&&o.maxlength)&&!((h=e.valid)!=null&&h.maxword)?(delete e.helperTxt,delete e.hlpTxtHide):x(e)):(e.valid||(e.valid={}),e.valid.minword=t,e.err||(e.err={}),e.err.minword||(e.err.minword={}),e.err.minword.dflt=v.minword||`<p style="margin:0">Minimum ${t} word required.</p>`,e.err.minword.show=!0,x(e));const a=M(c,u=>{u[i]=e});f(a),y(i),$({event:`Min word updated to ${t}: ${e.lbl||w||i}`,type:"set_minword",state:{fields:a,fldKey:i}})};return r.jsx(Q,{id:"text-length-stng",title:g("Min/Max Text Length:"),className:p(m.fieldSection),children:r.jsxs("div",{className:p({mx:5}),children:[r.jsxs("div",{className:p(m.fieldNumber,{py:"0px !important"}),children:[r.jsx("span",{children:g("Min Length:")}),r.jsx("input",{"data-testid":"text-length-stng-min-inp",title:"Minimum character length for this field","aria-label":"Minimum character length for this field",placeholder:"Type minimum length here...",className:p(m.input,m.w140),type:"number",min:"0",value:E,onChange:q})]}),((F=e.valid)==null?void 0:F.minlength)&&r.jsx(b,{id:"char-length-stng-min",type:"minlength",title:"Min Length Error Message",tipTitle:`${g("By enabling this feature, user will see the error message when input length is less than")} ${e.valid.minlength}`,allowIcons:!1}),r.jsxs("div",{className:p(m.fieldNumber,{py:"0px !important"}),children:[r.jsx("span",{children:g("Max Length:")}),r.jsx("input",{"data-testid":"char-length-stng-max-inp",title:"Maximum character length for this field","aria-label":"Maximum character length for this field",placeholder:"Type maximum length here...",className:p(m.input,m.w140),type:"number",min:"0",value:S,onChange:A})]}),((H=e.valid)==null?void 0:H.maxlength)&&r.jsx(b,{id:"char-length-stng-max",type:"maxlength",title:"Max Length Error Message",tipTitle:`${g("By enabling this feature, user will see the error message when input length is greater than")} ${e.valid.maxlength}`,allowIcons:!1}),r.jsxs("div",{className:p(m.fieldNumber,{py:"0px !important"}),children:[r.jsx("span",{children:g("Min Word:")}),r.jsx("input",{"data-testid":"char-length-stng-minword-inp",title:"Minimum word count for this field","aria-label":"Minimum word count for this field",placeholder:"Type minimum word count here...",className:p(m.input,m.w140),type:"number",min:"0",value:I,onChange:P})]}),((W=e.valid)==null?void 0:W.minword)&&r.jsx(b,{id:"char-length-stng-minword",type:"minword",title:"Min Word Error Message",tipTitle:`${g("By enabling this feature, user will see the error message when word count is less than")} ${e.valid.minword}`,allowIcons:!1}),r.jsxs("div",{className:p(m.fieldNumber,{py:"0px !important"}),children:[r.jsx("span",{children:g("Max Word:")}),r.jsx("input",{"data-testid":"char-length-stng-maxword-inp",title:"Maximum word count for this field","aria-label":"Maximum word count for this field",placeholder:"Type maximum word count here...",className:p(m.input,m.w140),type:"number",min:"0",value:B,onChange:K})]}),((_=e.valid)==null?void 0:_.maxword)&&r.jsx(b,{id:"char-length-stng-maxword",type:"maxword",title:"Max Word Error Message",tipTitle:`${g("By enabling this feature, user will see the error message when word count is greater than")} ${e.valid.maxword}`,allowIcons:!1})]})})}export{Be as default};
2