import { createElement } from "react";
import { NumberInput } from "@contember/ui";
import { useFieldControl } from "./useFieldControl.js";
import { SimpleRelativeSingleField } from "../auxiliary/SimpleRelativeSingleField/SimpleRelativeSingleField.js";
const parse = (value) => value ?? null;
const format = (value) => value ?? null;
const NumberField = SimpleRelativeSingleField((fieldMetadata, { defaultValue, ...props }) => {
  const inputProps = useFieldControl({
    ...props,
    fieldMetadata,
    parse,
    format
  });
  return /* @__PURE__ */ createElement(NumberInput, {
    ...inputProps
  });
}, "NumberField");
export { NumberField };
//# sourceMappingURL=NumberField.js.map
