From 2523a14844eec0dcd6b8456417895327a440e775 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon, 25 Nov 2024 19:10:25 +0000 Subject: [PATCH] [DataGrid] Fix row-spanning in combination with column-pinning (@lhilgert9) (#15460) Co-authored-by: Lucas Hilgert <77863078+lhilgert9@users.noreply.github.com> Co-authored-by: Bilal Shafi --- packages/x-data-grid/src/components/cell/GridCell.tsx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/x-data-grid/src/components/cell/GridCell.tsx b/packages/x-data-grid/src/components/cell/GridCell.tsx index 70614fecce353..54511abba199e 100644 --- a/packages/x-data-grid/src/components/cell/GridCell.tsx +++ b/packages/x-data-grid/src/components/cell/GridCell.tsx @@ -369,6 +369,10 @@ const GridCell = React.forwardRef(function GridCe if (rowSpan > 1) { cellStyle.height = `calc(var(--height) * ${rowSpan})`; cellStyle.zIndex = 5; + + if (isLeftPinned || isRightPinned) { + cellStyle.zIndex = 6; + } } return cellStyle;