UNPKG

@progress/kendo-react-grid

Version:

React Data Grid (Table) provides 100+ ready-to-use data grid features. KendoReact Grid package

43 lines (42 loc) 1.56 kB
/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2025 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- */ import a from "react"; import { GRID_COL_INDEX_ATTRIBUTE as i } from "../constants/index.mjs"; import { ReorderRowIcon as s } from "../components/icons/reorder-row-svg.mjs"; import { GridRowReorderCellContainer as m } from "./client/GridRowReorderContainer.mjs"; import { uGrid as R, classNames as r } from "@progress/kendo-react-common"; const f = (e) => { const { ...d } = e, t = e.unstyled, o = t && t.uGrid ? t.uGrid : R, c = r( o.td({ selected: e.isSelected, sorted: e.isSorted, alt: e.isAlt }), e.className ), l = { colSpan: e.colSpan, style: e.style, className: c, role: "gridcell", "aria-colindex": e.ariaColumnIndex, "aria-selected": e.isSelected, [i]: e.columnIndex }, n = r(l == null ? void 0 : l.className, [ "k-drag-cell", `${e.rowReorderable ? "" : "k-disabled"}` ]); return /* @__PURE__ */ a.createElement(m, { rowReorderable: e.rowReorderable, cellProps: d }, /* @__PURE__ */ a.createElement( "td", { ...l, style: { touchAction: "none" }, "aria-disabled": !e.rowReorderable, className: n }, /* @__PURE__ */ a.createElement(s, null) )); }; export { f as GridRowReorderCell };