import { jsxs as C, jsx as i } from "react/jsx-runtime";
import S from "../../../../utils/classNames.js";
import f from "./TableHeaderCellContent.js";
import h from "./TableHeaderCellResizeHandle.js";
import { resolveAriaSort as p } from "./resolveAriaSort.js";
import { resolveHeaderCellClassName as y } from "./resolveHeaderCellClassName.js";
import { resolveHeaderCellStyle as g } from "./resolveHeaderCellStyle.js";
import { resolveAriaSpan as n, resolveAriaColIndex as k } from "../../shared/resolveTableAria.js";
const N = (o) => {
  const {
    column: e,
    header: l,
    hideWhileDragging: m,
    htmlAttributes: s,
    isResizable: c,
    showSelectionColumn: t,
    stickyLeftColumnCount: u,
    stickyRightColumnCount: d
  } = o, r = u ?? 0, a = d ?? 0;
  return /* @__PURE__ */ C(
    "div",
    {
      ...s,
      className: S(
        y(e, l, {
          isResizable: c,
          isStickyLeftColumn: r > 0 && e.columnStart <= r,
          isStickyRightColumn: a > 0 && e.columnStart + e.colSpan - 1 > l.totalColumnCount - a
        }),
        m && "table-head-cell-drag-placeholder"
      ),
      "data-column": e.columnKey ?? String(e.key),
      role: "columnheader",
      "aria-colindex": k(e.columnStart, t),
      "aria-colspan": n(e.colSpan),
      "aria-rowindex": e.rowStart,
      "aria-rowspan": n(e.rowSpan),
      "aria-sort": p(e),
      style: g(e, t),
      children: [
        /* @__PURE__ */ i(f, { ...o }),
        /* @__PURE__ */ i(h, { ...o })
      ]
    }
  );
};
export {
  N as default
};
//# sourceMappingURL=TableStaticHeaderCell.js.map
