import{template as e}from"@gem-sdk/core";import{getDynamicSourceLocales as m,createSettingId as t}from"../../../helpers.js";import{createStyle as s,createClass as a,If as i}from"@gem-sdk/system";import{composeContainerStyles as o,composeInnerStyles as l}from"./common/styles.js";import{composeContainerClasses as r,composeInnerClasses as p,getClassTitle as d}from"./common/classes.js";import{FormEmail as n}from"../../settings/form-email/configs/translate.js";let FormEmail=({builderProps:$,builderAttrs:c,setting:u,advanced:f,pageContext:g,styles:y})=>{let{placeholder:j,required:v,hideOnClient:h,defaultEmail:E,showTitle:F,title:k}=u??{},q=m({val:j,uid:$?.uid,settingId:t({id:n?.placeholder?.id}),pageContext:g??{}}),x=s(o(u,f)),C=s(l(u,f,y)),I=a(r({setting:u,advanced:f,builderProps:$,type:"liquid"})),N=a(p(u,$)),b=a(d());return e`
    <div
      ${{...c}}
      data-id="${$?.uid}"
      class="${I}"
      style="${x}"
    >
      ${i(F,`<span className="${b}">${k}</span>`)}
      <input
        type="email"
        class="${N}"
        style="${C}"
        placeholder="${q}"
        name="${"contact[email]"}"
        ${i(v,"required")}
        autocomplete="email"
        ${i(h,`value="${E}"`)}
      ></input>
    </div>
  `};export{FormEmail as default};
