@mui/x-data-grid-premium
Version:
The Premium plan edition of the MUI X Data Grid Components.
21 lines • 732 B
JavaScript
import _extends from "@babel/runtime/helpers/esm/extends";
import { vars, GridFooterCell } from '@mui/x-data-grid-pro/internals';
import { useGridRootProps } from "../hooks/utils/useGridRootProps.mjs";
import { jsx as _jsx } from "react/jsx-runtime";
function GridGroupingColumnFooterCell(props) {
const rootProps = useGridRootProps();
const sx = {
ml: 0
};
if (props.rowNode.parent == null) {
sx.ml = 0;
} else if (rootProps.rowGroupingColumnMode === 'multiple') {
sx.ml = 2;
} else {
sx.ml = `calc(var(--DataGrid-cellOffsetMultiplier) * ${vars.spacing(props.rowNode.depth)})`;
}
return /*#__PURE__*/_jsx(GridFooterCell, _extends({
sx: sx
}, props));
}
export { GridGroupingColumnFooterCell };