UNPKG

@progress/kendo-react-grid

Version:

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

27 lines (26 loc) 1.12 kB
/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2025 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- */ "use client"; import * as i from "react"; import { GridContext as s } from "../../utils/GridContext.mjs"; import { useTableKeyboardNavigation as m } from "@progress/kendo-react-data-tools"; import { useLocalization as l } from "@progress/kendo-react-intl"; import { gridRowReorderAriaLabel as o, messages as u } from "../../messages/index.mjs"; import { useContextMenuHandler as d } from "../hooks.mjs"; const x = (e) => { const t = l(), a = i.useContext(s), n = m(e.id), r = d(e.dataItem, e.field); return { "aria-label": t.toLanguageString(o, u[o]), ...n, onMouseDown: () => e.rowReorderable ? a.activeDragRowDataItemRef.current = e.dataItem : null, onContextMenu: r }; }; export { x as useRowReorderCellClientTdProps };