const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./widget-DZZgQDKu.css","./Hint-BAxc7GHP.css","./Default-CQTAksNp.css","./BoxToggleWithDescription-CXcc1aCJ.css"])))=>i.map(i=>d[i]);
import{a as D,C as q,b as m,e as f,_ as b,m as o,g as s,p as l,q as r,f as v,u as e,L as A,D as n,r as V,I as E}from"./convert-case-to-camel-case.utils-DDUpNI96.js";import{u as P}from"./widget-BUAABBRb.js";import{u as S}from"./useMultiOptionsFieldShared-B94LQkbD.js";import{_ as T}from"./RequiredHint.vue_vue_type_style_index_0_lang-R4Bqx90z.js";import"./_commonjsHelpers-Cpj98o6Y.js";import"./_commonjs-dynamic-modules-TDtrdbi3.js";import"./translationsStore-DBJu9sBR.js";const B={class:"ccb-field__label"},R={class:"ccb-field__title"},I={key:0,class:"ccb-field-required-mark"},L={key:0,class:"ccb-field__descriptions ccb-before"},N={key:0,class:"ccb-field__description"},O={class:"ccb-field__input-wrapper"},w={key:1,class:"ccb-field__descriptions ccb-after"},U={key:0,class:"ccb-field__description"},H=D({__name:"Toggle",props:{field:{}},setup(y){const d=y,{field:t}=q(d),p=P(),{applyChanges:g,isRequired:_,fieldValue:h,requiredWarningText:C}=S(d),k=m(()=>{var c,a;const i=((a=(c=t.value)==null?void 0:c.styles)==null?void 0:a.style)||"default";return i==="default"?f(()=>b(()=>import("./Default-BEkPEAGl.js"),__vite__mapDeps([0,1,2]),import.meta.url)):i==="box-with-toggle-and-description"?f(()=>b(()=>import("./BoxToggleWithDescription-nPbUEoji.js"),__vite__mapDeps([0,3]),import.meta.url)):""}),x=m(()=>{var i;return((i=t.value)==null?void 0:i.additionalStyles)||""});return(i,c)=>{var a,u;return s(),o("div",{class:E(["ccb-field ccb-toggle-field",{required:e(_),"ccb-field-disabled":e(t).disabled,[`ccb-field-element-columns-${(a=e(t).styles)==null?void 0:a.elementColumns}`]:(u=e(t).styles)==null?void 0:u.elementColumns,[x.value]:!0}])},[l("div",B,[e(_)?(s(),v(T,{key:0,text:e(C)},null,8,["text"])):r("",!0),l("div",R,[A(n(e(t).label),1),e(t).required?(s(),o("span",I,"*")):r("",!0)])]),e(p).getAppearanceDescriptionPosition==="before"?(s(),o("div",L,[e(t).description?(s(),o("div",N,n(e(t).description),1)):r("",!0)])):r("",!0),l("div",O,[(s(),v(V(k.value),{values:e(h),onUpdate:e(g),field:e(t)},null,40,["values","onUpdate","field"]))]),e(p).getAppearanceDescriptionPosition==="after"?(s(),o("div",w,[e(t).description?(s(),o("div",U,n(e(t).description),1)):r("",!0)])):r("",!0)],2)}}});export{H as default};
//# sourceMappingURL=index-Dbhw-jN0.js.map
