UNPKG

react-forminate

Version:

React.js + Typescript package that creates dynamic UI forms based on the JSON schema

21 lines (20 loc) 488 B
import { u as n, j as r } from "./index-BPZpMa2Y.js"; import { I as p } from "./FieldComponents-Fikvpz9O.js"; import m from "react"; const u = (t) => { const { eventHandlers: s, value: o, error: l, props: a, fieldParams: i } = n(t), e = { ...i, ...s.htmlHandlers, value: o }; return a.disableDefaultStyling ? /* @__PURE__ */ r.jsx("input", { ...e }) : /* @__PURE__ */ r.jsx(p, { ...e, hasError: !!l }); }, x = m.memo(u); export { x as default };