Skip to content

Conversation

KenanYusuf
Copy link
Member

@KenanYusuf KenanYusuf commented Feb 5, 2025

Preview: https://deploy-preview-16476--material-ui-x.netlify.app/x/react-data-grid/column-pinning/#pinned-columns-appearance

Conditional scroll shadows

Adds conditional scroll shadows when there are pinned columns and rows. Closes #10001

Screen.Recording.2025-06-25.at.11.05.46.mov

Vertical scrollbar changes

Update vertical scrollbar positioning to cover pinned rows (previous discussion #16379). TLDR; this is a usability improvement, as it currently doesn't look as though you can scroll vertically over pinned rows.

Also fixes #13286

Browser Before After
Chrome, macOS mac chrome before mac chrome after
Edge, Windows 11 windows edge before windows edge after
Chrome, Windows 11 windows chrome before windows chrome after

Changelog

  • Updated vertical scrollbar to include pinned rows and aggregation sections
  • Improved the appearance of pinned columns and pinned rows sections

@KenanYusuf KenanYusuf added scope: data grid Changes related to the data grid. design This is about UI or UX design, please involve a designer. labels Feb 5, 2025
@KenanYusuf KenanYusuf changed the title [data grid] Update vertical position to cover pinned rows [data grid] Update vertical scrollbar position to cover pinned rows Feb 5, 2025
@mui-bot
Copy link

mui-bot commented Feb 5, 2025

Deploy preview: https://deploy-preview-16476--material-ui-x.netlify.app/

Updated pages:

Bundle size report

Bundle Parsed size Gzip size
@mui/x-data-grid 🔺+2.3KB(+0.59%) 🔺+577B(+0.49%)
@mui/x-data-grid-pro 🔺+2.64KB(+0.56%) 🔺+595B(+0.42%)
@mui/x-data-grid-premium 🔺+2.49KB(+0.40%) 🔺+603B(+0.32%)
@mui/x-charts 0B(0.00%) 0B(0.00%)
@mui/x-charts-pro 0B(0.00%) 0B(0.00%)
@mui/x-charts-premium 0B(0.00%) 0B(0.00%)
@mui/x-date-pickers 0B(0.00%) 0B(0.00%)
@mui/x-date-pickers-pro 0B(0.00%) 0B(0.00%)
@mui/x-tree-view 0B(0.00%) 0B(0.00%)
@mui/x-tree-view-pro 0B(0.00%) 0B(0.00%)

Details of bundle changes

Generated by 🚫 dangerJS against 612f420

@github-actions github-actions bot added the PR: out-of-date The pull request has merge conflicts and can't be merged. label Feb 5, 2025
Copy link

github-actions bot commented Feb 5, 2025

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@github-actions github-actions bot added PR: out-of-date The pull request has merge conflicts and can't be merged. and removed PR: out-of-date The pull request has merge conflicts and can't be merged. labels Feb 6, 2025
Copy link

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@github-actions github-actions bot added PR: out-of-date The pull request has merge conflicts and can't be merged. and removed PR: out-of-date The pull request has merge conflicts and can't be merged. labels Feb 17, 2025
Copy link

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@github-actions github-actions bot removed the PR: out-of-date The pull request has merge conflicts and can't be merged. label Apr 15, 2025
bottom: 0,
});

export const ScrollbarCorner = styled(Scrollbar)({
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This corner piece covers up the dead zone between the two scrollbars.

Without With
Screenshot 2025-05-21 at 17 01 47 Screenshot 2025-05-21 at 17 01 16

@KenanYusuf KenanYusuf changed the title [data grid] Update vertical scrollbar position to cover pinned rows [DataGrid] Update vertical scrollbar position to cover pinned rows May 22, 2025
@KenanYusuf KenanYusuf marked this pull request as ready for review May 22, 2025 12:59
@KenanYusuf KenanYusuf force-pushed the vertical-scrollbar-include-pinned-rows branch from 89a113a to 9707912 Compare May 22, 2025 14:10
Comment on lines 278 to 281
dimensions.minimumSize.height - dimensions.viewportOuterSize.height,
dimensions.contentSize.height - dimensions.viewportInnerSize.height,
);
const maxScrollLeft = Math.ceil(
dimensions.minimumSize.width - dimensions.viewportInnerSize.width,
dimensions.contentSize.width - dimensions.viewportInnerSize.width,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Iiuc, this is a bugfix for the virtualization code?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, if I'm remembering correctly it fixes a miscalculation.

Copy link

github-actions bot commented Sep 9, 2025

This pull request has been inactive for 30 days. Please remove the stale label or leave a comment to keep it open. Otherwise, it will be closed in 15 days.

@github-actions github-actions bot added the stale Inactive for 7 days (issues) or 30 days (PRs); closed after 5 or 15 more days if no update. label Sep 9, 2025
@github-actions github-actions bot removed the PR: out-of-date The pull request has merge conflicts and can't be merged. label Sep 15, 2025
@cherniavskii cherniavskii added type: enhancement It’s an improvement, but we can’t make up our mind whether it's a bug fix or a new feature. and removed stale Inactive for 7 days (issues) or 30 days (PRs); closed after 5 or 15 more days if no update. labels Sep 16, 2025
@cherniavskii
Copy link
Member

OK, this PR is ready for review again.
@romgrk any objections on your side?

@cherniavskii cherniavskii merged commit ecbf734 into mui:master Sep 29, 2025
21 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
design This is about UI or UX design, please involve a designer. scope: data grid Changes related to the data grid. type: enhancement It’s an improvement, but we can’t make up our mind whether it's a bug fix or a new feature.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[data grid] Scrollbar overlap [data grid] Improve pinning shadow design
6 participants