"use strict";const t=require("@tempots/dom"),s=require("./input-container-B31Seozh.cjs"),p=({autocomplete:n,autofocus:r,classes:e,disabled:u,name:a,placeholder:l,id:i,required:m,tabIndex:c,hasError:o})=>t.Fragment(t.attr.autocomplete(n),t.attr.autofocus(r),t.attr.class(e?.input),t.attr.disabled(u),t.attr.name(a??i),t.attr.placeholder(l),t.attr.id(i),t.aria.required(m),t.attr.tabindex(c),o!=null?t.aria.invalid(o??!1):null),d=n=>{const{value:r,onBlur:e,onChange:u,onInput:a,type:l}=n;return s.InputContainer({...n,input:t.html.input(t.attr.type(l??"text"),p(n),t.attr.value(r),t.attr.class("bc-input"),e!=null?t.on.blur(t.emitValue(e)):t.Empty,u!=null?t.on.change(t.emitValue(u)):t.Empty,a!=null?t.on.input(t.emitValue(a)):t.Empty)})};exports.CommonInputAttributes=p;exports.TextInput=d;
