System.register(["../../../../common/preload-helper-legacy.CIXZiioE.js","../../index-legacy.CKwsq3d1.js","../../../../common/GroupControl.vue_vue_type_style_index_0_scoped_ac0e52be_lang-legacy.BhDSN6Mf.js","../../../../common/DnDDataTableControl.vue_vue_type_style_index_0_scoped_0b913e4f_lang-legacy.D1tDIuyM.js","../../../../common/GroupConditionalControl.vue_vue_type_style_index_0_scoped_96558d5e_lang-legacy.CHJO3hx-.js","../../../../common/LabelControl.vue_vue_type_script_setup_true_lang-legacy.9mLv6sKk.js","../../../../common/OptionsControl.vue_vue_type_style_index_0_scoped_f1f8db36_lang-legacy.Czfm27ET.js","../../../../common/index-legacy.fuZ4twhd.js","../../../../common/index-legacy.CO4MsCT9.js","../../../../common/motion-legacy.C4TziduP.js","../../../../common/KeyCode-legacy.Cey0FNFJ.js","../../../../common/index-legacy.M32zB8dq.js","../../../../common/useState-legacy.C_VuFIfe.js","../../../../common/FormItemContext-legacy.CWXRIB7M.js","../../../../common/createContext-legacy.DxkS4L9s.js"],function(e,l){"use strict";var n,o,a,c,t,u,d,i,s,r,_,m,p;return{setters:[e=>{n=e.d,o=e.ar,a=e.A,c=e.r,t=e.bn,u=e.bo,d=e.bp,i=e.h,s=e.a9,r=e.br},e=>{_=e.p},null,null,null,e=>{m=e._},null,e=>{p=e.A},null,null,null,null,null,null,null],execute:function(){const l={class:"wwp-row-handle"},v={class:"wwp-left-content"},y={class:"wwp-right-content"},g=["innerHTML"];e("default",n({__name:"SwitchControl",props:{params:{type:Object,required:!0},conditionalValues:{type:Object,required:!1,default:()=>({})}},emits:["conditionalData","fieldData"],setup(e,{emit:n}){const h=e,j=n,{params:f,conditionalValues:b}=o(h),k=f.value,x=a(b.value[k.id]?b.value[k.id]:k.default),C=c({check:"yes"===x.value}),w=a(k.options.yes),D=a(k.options.no),q=a([]);return x.value&&(q.value[k.id]=x.value,j("fieldData",q.value)),(e,n)=>{var o,a;return t(),u("div",l,[d("div",v,[i(s(m),{params:s(k)},null,8,["params"])]),d("div",y,[i(s(p),{checked:C.check,"onUpdate:checked":n[0]||(n[0]=e=>C.check=e),"checked-children":w.value,"un-checked-children":D.value,onChange:n[1]||(n[1]=e=>{return l=e,x.value=l?"yes":"no",q.value[k.id]=x.value,C.check=l,j("conditionalData",q.value),void j("fieldData",q.value);var l})},null,8,["checked","checked-children","un-checked-children"]),"undefined"!==s(k).description?(t(),u("p",{key:0,innerHTML:s(_)(null!==(o=null===(a=s(k))||void 0===a?void 0:a.description)&&void 0!==o?o:"")},null,8,g)):r("",!0)])])}}}))}}});
