import { jsx as _jsx } from "react/jsx-runtime";
import { TextField } from "./TextField.native.js";
function NumericalInput(param) {
  var {
    value,
    onChange,
    ...props
  } = param;
  return /* @__PURE__ */_jsx(TextField, {
    ...props,
    keyboardType: "decimal-pad",
    onChangeText: function (e) {
      var newValue = e?.replace(/[^0-9.]/g, "").replace(/(\..*)\./g, "$1");
      onChange && onChange(newValue);
    },
    value: value?.toString()
  });
}
export { NumericalInput };
//# sourceMappingURL=NumericalInput.native.js.map
