import{template as e}from"@gem-sdk/core";import{getDynamicSourceLocales as s}from"../../../helpers.js";import{createStyle as t,createClass as o,If as m}from"@gem-sdk/system";import{composeContainerStyles as r,composeFormCheckboxStyles as l,composeFormCheckboxInputStyles as i,getComposedTextStyle as a}from"./common/styles.js";import{composeContainerClasses as c,composeFormCheckboxInputClasses as d,composeFormCheckboxLabelClasses as p}from"./common/classes.js";let FromCheckbox=({builderProps:$,setting:n,advanced:u,pageContext:y,styles:f})=>{let{name:k,description:b,selected:h,required:x,translate:g}=n??{},j=s({val:b,uid:$?.uid,settingId:"description",pageContext:y,translate:g}),v=t(r(n)),C=t(l(n,f,$)),F=t(i()),q=t(a(n)),I=o(c(n,u,$)),w=o(d()),z=o(p());return e`
    <div
      data-id="${$?.uid}"
      style="${v}"
    >
      <label
        style="${C}"
        class="${I}"
      >
        <input
          class="${w}"
          name="${k}"
          type="checkbox"
          ${m(h,"checked")}
          ${m(x,"required")}
          style="${F}"
        >
        </input>
        <span class="${z}" style="${q}">
          ${j}
        </span>
      </label>
    </div>
  `};export{FromCheckbox as default};
