import { jsx as l } from "@emotion/react/jsx-runtime";
import { SELECT_COLUMN_KEY as i } from "react-data-grid";
import { useDataGrid as d } from "../../../../hooks/shared/useDataGrid/useDataGrid.js";
import { RadioFormatter as c } from "./subcomponents/RadioFormatter/RadioFormatter.js";
function s(e) {
  return null;
}
function m(e) {
  const { checkedRows: t, onCheckedRowsChange: r, rowKeyGetter: o } = d(), n = (a, u) => {
    a ? r && r(/* @__PURE__ */ new Set([o(e.row)])) : r && r(/* @__PURE__ */ new Set());
  };
  return /* @__PURE__ */ l(
    c,
    {
      checked: t?.has(o(e.row)) || !1,
      tabIndex: e.tabIndex,
      onChange: n,
      "aria-label": "Select"
    }
  );
}
function f(e) {
  return null;
}
const w = {
  key: i,
  name: "",
  width: 32,
  minWidth: 32,
  isDraggable: !1,
  resizable: !1,
  sortable: !1,
  frozen: !0,
  type: "boolean",
  renderHeaderCell: f,
  renderCell: m,
  renderGroupCell: s
};
export {
  w as RadioSelectColumn,
  f as RadioSelectColumnHeaderRenderer,
  m as RadioSelectFormatter,
  s as RadioSelectGroupFormatter
};
