import * as e from "react";
import { useContext as a, useMemo as l } from "react";
import "../../../rc-field-form/es/index.mjs";
import p from "../../../rc-util/es/omit.mjs";
import { FormProvider as x } from "../../../rc-field-form/es/FormContext.mjs";
const I = /* @__PURE__ */ e.createContext({
  labelAlign: "right",
  vertical: !1,
  itemRef: () => {
  }
}), F = /* @__PURE__ */ e.createContext(null), v = (o) => {
  const r = p(o, ["prefixCls"]);
  return /* @__PURE__ */ e.createElement(x, Object.assign({}, r));
}, P = /* @__PURE__ */ e.createContext({
  prefixCls: ""
}), n = /* @__PURE__ */ e.createContext({});
process.env.NODE_ENV !== "production" && (n.displayName = "FormItemInputContext");
const b = (o) => {
  let {
    children: r,
    status: m,
    override: s
  } = o;
  const i = a(n), c = l(() => {
    const t = Object.assign({}, i);
    return s && delete t.isFormItemInput, m && (delete t.status, delete t.hasFeedback, delete t.feedbackIcon), t;
  }, [m, s, i]);
  return /* @__PURE__ */ e.createElement(n.Provider, {
    value: c
  }, r);
};
export {
  I as FormContext,
  n as FormItemInputContext,
  P as FormItemPrefixContext,
  v as FormProvider,
  b as NoFormStyle,
  F as NoStyleItemContext
};
