import{j as s,g as b,ap as g,b2 as y,D as F,bd as N,cG as j,_ as S,dz as C,da as k,dc as h,a2 as D,db as $,dd as L,a as z,d7 as M}from"./main-634.js";import{T as P,D as R,p as T,q as G,r as B,C as E,R as O,N as W,t as U,P as H,U as _,u as A,v as I,M as q,W as J,w as Q,x as V,G as X,B as Y,y as Z,z as K,I as ss,J as es,K as ts,L as is,O as as,Q as ns,X as rs,Y as cs,Z as os,_ as ls,$ as ds,a0 as ms,a1 as xs,E as ps}from"./bf-692-111.js";import{A as js}from"./bf-838-80.js";import{g as hs}from"./bf-25-81.js";import{D as Is}from"./bf-284-252.js";import{R as us}from"./bf-17-106.js";import{S as zs}from"./bf-400-72.js";import{U as u}from"./bf-671-253.js";import"./bf-982-242.js";import"./bf-497-246.js";import"./bf-641-107.js";import"./bf-486-243.js";import"./bf-723-244.js";import"./bf-299-245.js";import"./bf-534-247.js";import"./bf-962-248.js";import"./bf-343-249.js";import"./bf-791-250.js";import"./bf-570-251.js";import"./bf-334-254.js";import"./bf-297-103.js";import"./bf-438-114.js";function vs({w:t}){return s.jsxs("svg",{className:"btc-line-icn",viewBox:"0 0 172.3 163.8",width:t,children:[s.jsx("path",{className:"line-icn",d:`M146.6,150.5h-118c-11.4,0-20.7-9.3-20.7-20.7V28.7C8,17.3,17.3,8,28.7,8h118c11.4,0,20.7,9.3,20.7,20.7v101.1
          C167.3,141.2,158.1,150.5,146.6,150.5z`}),s.jsx("path",{className:"line-icn",strokeWidth:"12",d:"M31.5,106.2l34-47.6c2.1-3,6.5-3.1,8.8-0.2l31.4,39.5"}),s.jsx("path",{className:"line-icn",strokeWidth:"12",d:"M93.2,86l12.8-15.1c2.1-3,6.5-3.1,8.8-0.2l31.4,39.5"}),s.jsx("path",{className:"line-icn",strokeWidth:"9",d:`M126,38.3L126,38.3c-2.1,0-3.8-1.7-3.8-3.8v0c0-2.1,1.7-3.8,3.8-3.8h0c2.1,0,3.8,1.7,3.8,3.8v0
          C129.8,36.6,128.1,38.3,126,38.3z`})]})}function fs({icn:t,title:n,subTitle:r,fieldKey:i,type:e}){const{formType:a,formID:c}=b(),l=g(y),d=F(),o=N(`.${i}-fld-wrp.drag`),f=()=>{l(i),o&&o.classList.remove("drag-hover"),d(`/form/builder/${a}/${c}/field-settings/${i}`)},x=w=>{if(!o)return;const{type:p}=w;p==="mouseenter"?o.classList.add("drag-hover"):p==="mouseleave"&&o.classList.remove("drag-hover")};return s.jsx("button",{type:"button","data-testid":`fld-lst-itm-${t}-${i}`,onClick:f,onMouseEnter:x,onMouseLeave:x,className:"btc-s-l mt-2",children:s.jsxs("div",{className:"flx flx-between ",children:[s.jsxs("div",{className:"flx w-9",children:[s.jsx("span",{className:"lft-icn mr-2 flx br-50",children:typeof t=="string"?ws(t):t}),s.jsxs("div",{className:"w-nwrp o-h",children:[s.jsx("div",{className:"txt-o o-h mb-1",children:j(n)}),s.jsxs("div",{children:[e&&s.jsx("small",{className:"mr-2",children:` ${j(e)}`}),r&&s.jsxs("small",{children:[S("Key:"),` ${r}`]})]})]})]}),s.jsx(C,{size:18})]})})}const ws=t=>({title:s.jsx(P,{w:"14"}),divider:s.jsx(R,{w:"14"}),spacer:s.jsx(T,{size:"17"}),image:s.jsx(vs,{w:"14"}),text:s.jsx(G,{size:"14"}),name:s.jsx(u,{size:"14"}),username:s.jsx(u,{size:"14"}),textarea:s.jsx(B,{size:"14"}),check:s.jsx(E,{w:"14"}),radio:s.jsx(O,{size:"14"}),number:s.jsx(W,{w:"14"}),"html-select":s.jsx(hs,{size:"14"}),select:s.jsx(U,{w:"14"}),password:s.jsx(H,{size:"14"}),email:s.jsx(k,{size:"14"}),url:s.jsx(_,{w:"14"}),"file-up":s.jsx(h,{w:"14"}),date:s.jsx(Is,{w:"14"}),time:s.jsx(A,{size:"14"}),"datetime-local":s.jsx(I,{w:"14"}),month:s.jsx(q,{w:"14"}),week:s.jsx(J,{size:"14"}),color:s.jsx(Q,{w:"14"}),recaptcha:s.jsx(us,{size:"14"}),"decision-box":s.jsx(V,{size:"14"}),gdpr:s.jsx(X,{size:"14"}),button:s.jsx(Y,{size:"14"}),html:s.jsx(D,{size:"14"}),shortcode:s.jsx(zs,{size:"14"}),paypal:s.jsx(Z,{w:"14"}),stripe:s.jsx(K,{size:"18"}),mollie:s.jsx(ss,{size:"18"}),razorpay:s.jsx(es,{w:"14",h:"19"}),"advanced-file-up":s.jsx(h,{w:"14"}),currency:s.jsx(ts,{size:"15"}),"phone-number":s.jsx(is,{size:"15"}),country:s.jsx(as,{size:"14"}),section:s.jsx(ns,{size:"14"}),repeater:s.jsx(rs,{size:"14"}),rating:s.jsx($,{size:"18"}),signature:s.jsx(cs,{size:"18"}),"image-select":s.jsx(os,{size:"16"}),turnstile:s.jsx(ls,{size:"16"}),hcaptcha:s.jsx(ds,{size:"16"}),range:s.jsx(ms,{size:"16"}),hidden:s.jsx(L,{size:"15"}),"advanced-datetime":s.jsx(I,{w:"14"}),"email-otp":s.jsx(xs,{size:"16"}),address:s.jsx(js,{size:"14"})})[t];function m(){const{css:t}=z(),n=M(),r=Object.entries(n).filter(([,e])=>{var a;return(a=e==null?void 0:e.valid)==null?void 0:a.hide}),i=Object.entries(n).filter(([,e])=>{var a;return!((a=e==null?void 0:e.valid)!=null&&a.hide)});return s.jsxs("div",{className:t(v.wrapper),children:[s.jsx(m.Group,{title:`Hidden Fields (${r.length})`,filteredFields:r}),s.jsx(m.Group,{title:`Fields (${i.length})`,filteredFields:i}),r.length===0&&i.length===0&&s.jsx(ps,{})]})}const bs=({title:t,filteredFields:n})=>{const{css:r}=z();return n.length?s.jsxs("div",{children:[s.jsx("div",{className:r(v.title),children:t}),n.map(([i,e])=>{let{lbl:a}=e;const{typ:c,adminLbl:l,txt:d}=e;return["decision-box","gdpr"].includes(c)?a=l:c==="button"&&(a=d),s.jsx(fs,{fieldKey:i,icn:c,title:a||l||c,type:c,subTitle:i},i)})]}):s.jsx(s.Fragment,{children:" "})};m.Group=bs;const v={wrapper:{p:" 10px 15px",ovy:"auto",h:"100%"},title:{fw:500,fs:16,pn:"sticky",pt:14,tp:0,bd:"var(--white)",h:40,bb:"1px solid var(--bf-stroke-clr)"},emptyStateWrapper:{ta:"center",p:20,cr:"#666",fs:14},emptyStateDescription:{mt:5,cr:"#999",fs:12},emptyIcon:{mb:10},emptyStateTitle:{fs:18,fw:"var(--bf-font-semibold)",color:"#4b5563",mb:8}};export{m as default};
