import { jsx } from "react/jsx-runtime";
import {
  DSControlledCheckbox
} from "@elliemae/ds-controlled-form";
import {
  Controller
} from "react-hook-form";
const CheckBox = ({
  name,
  defaultValue,
  rules = {},
  ...rest
}) => /* @__PURE__ */ jsx(
  Controller,
  {
    name,
    rules,
    defaultValue,
    render: ({ field: { value, ...restProps } }) => /* @__PURE__ */ jsx(DSControlledCheckbox, { ...rest, ...restProps, checked: Boolean(value) })
  }
);
export {
  CheckBox
};
