UNPKG

fui-fancyui

Version:
76 lines (75 loc) 1.57 kB
"use client"; import { jsx as p } from "react/jsx-runtime"; import { forwardRef as j, useState as w, useId as E } from "react"; import M from "../../atoms/TextInput/TextInput.js"; import N from "../../molecules/InputWrapper/InputWrapper.js"; const q = j((c, m) => { const { id: t, value: r, themeType: f = "primary", layer: y = 2, placeholder: n, systemMessage: I, disabled: o, align: s, icon: g, label: x, onFocus: a, type: B = "text", underline: h, onBlur: u, outlined: v, outlinedBackgroundStrength: b, outlinedRemoveBorder: F, transparentBackground: T, className: k, readOnly: i, ...A } = c, [R, l] = w(!1), S = E(), d = t || S; return /* @__PURE__ */ p( N, { id: d, hasValue: !!r, label: x, disabled: o || i, placeholder: n, themeType: f, layer: y, align: s, isActive: R, underline: h, icon: g, className: k, systemMessage: I, transparentBackground: T, outlined: v, outlinedBackgroundStrength: b, outlinedRemoveBorder: F, InputElement: /* @__PURE__ */ p( M, { ref: m, id: d, value: r, align: s, type: B, disabled: o, readOnly: i, onFocus: (e) => { a && a(e), l(!0); }, onBlur: (e) => { u && u(e), l(!1); }, placeholder: n, ...A } ) } ); }); export { q as default };