import { jsx as h } from "react/jsx-runtime";
import { useTableContext as _ } from "../../context/index.js";
import { cn as r } from "../../../../utils/functions.js";
import "../../../../context/index.js";
import "react";
import "../../../../clsx-7d8NmkQq.js";
const f = ({ className: i, targetId: c, oneTarget: m, ...a }) => {
  const [o = {}, n] = _((t) => t.checkedData), { data: e } = { ...a }, s = () => {
    o[e[c]] ? n((t) => {
      delete t.checkedData[e[c]];
    }) : n((t) => {
      m ? t.checkedData = {
        [e[c]]: e
      } : t.checkedData = {
        ...t.checkedData,
        [e[c]]: e
      };
    });
  };
  return /* @__PURE__ */ h(
    "input",
    {
      ...a,
      checked: !!o[e[c]],
      onChange: s,
      className: r("cs3__form__radio__input _mx-auto _flex _justify-center _items-center _mt-0.5", i),
      type: "radio"
    }
  );
};
export {
  f as default
};
