import { jsxs as u, jsx as r } from "react/jsx-runtime";
import { S as I } from "./search-input-BDUJ48BC.es.js";
import { F as e } from "./form-field-BfDU18h3.es.js";
import { F as S } from "./field-errors-D1BQvoYg.es.js";
const x = ({
  id: o,
  label: t,
  description: a,
  info: s,
  errors: l,
  renderError: c,
  touched: d = !1,
  isRequired: m = !1,
  isDisabled: h = !1,
  isReadOnly: p = !1,
  isInvalid: f = !1,
  size: i = "md",
  ...F
}) => {
  const n = d && l && Object.values(l).some(Boolean);
  return /* @__PURE__ */ u(
    e.Root,
    {
      id: o,
      size: i,
      isInvalid: n || f,
      isRequired: m,
      isDisabled: h,
      isReadOnly: p,
      children: [
        /* @__PURE__ */ r(e.Label, { children: t }),
        /* @__PURE__ */ r(e.Input, { children: /* @__PURE__ */ r(I, { size: i, ...F }) }),
        a && /* @__PURE__ */ r(e.Description, { children: a }),
        s && /* @__PURE__ */ r(e.InfoBox, { children: s }),
        n && /* @__PURE__ */ r(e.Error, { children: /* @__PURE__ */ r(
          S,
          {
            id: `${o}-errors`,
            errors: l,
            renderError: c
          }
        ) })
      ]
    }
  );
};
x.displayName = "SearchInputField";
export {
  x as S
};
//# sourceMappingURL=search-input-field-CEemw2P1.es.js.map
