import { jsx as r } from "react/jsx-runtime";
import { C as h } from "../../../../index-OHO5PlsB.js";
import { useTableContext as n } from "../../context/index.js";
import "react";
import "../../../../utils/functions.js";
import "../../../../clsx-7d8NmkQq.js";
import "../../../../utils/components/RenderEach.js";
import "../../../../utils/components/RenderIf.js";
import "../../../Icons.js";
import "../../../Inputs/variants.js";
import "../../../../index-xVF7D3FM.js";
import "../../../../motion-dVICNqWI.js";
import "../../../../SVGVisualElement-aqO4D4Z5.js";
import "../../../../LayoutGroupContext-3euHzeKi.js";
import "../../../../context/index.js";
const v = ({ targetId: t, oneTarget: m, ...c }) => {
  const [a = {}, i] = n((o) => o.checkedData), { data: e } = { ...c }, p = () => {
    a[e[t]] ? i((o) => {
      delete o.checkedData[e[t]];
    }) : i((o) => {
      m ? o.checkedData = {
        [e[t]]: e
      } : o.checkedData = {
        ...o.checkedData,
        [e[t]]: e
      };
    });
  };
  return /* @__PURE__ */ r(
    h,
    {
      inputProps: {
        disabled: !0,
        checked: !!a[e[t]],
        onChange: p,
        ...c
      }
    }
  );
};
export {
  v as default
};
