Skip to content

Conversation

@bernardobelchior
Copy link
Member

@bernardobelchior bernardobelchior commented Dec 18, 2025

Fixes #20622.

Screen.Recording.2025-12-19.at.15.11.16.mov

@bernardobelchior bernardobelchior added type: new feature Expand the scope of the product to solve a new problem. scope: charts Changes related to the charts. labels Dec 18, 2025
@mui-bot
Copy link

mui-bot commented Dec 18, 2025

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

Updated pages:

Bundle size report

Bundle Parsed size Gzip size
@mui/x-data-grid 0B(0.00%) 0B(0.00%)
@mui/x-data-grid-pro 0B(0.00%) 0B(0.00%)
@mui/x-data-grid-premium 0B(0.00%) 0B(0.00%)
@mui/x-charts 0B(0.00%) 0B(0.00%)
@mui/x-charts-pro 🔺+19B(0.00%) ▼-13B(-0.01%)
@mui/x-charts-premium 🔺+9B(0.00%) ▼-1B(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 848592d

@codspeed-hq
Copy link

codspeed-hq bot commented Dec 18, 2025

CodSpeed Performance Report

Merging #20708 will not alter performance

Comparing bernardobelchior:heatmap-zoom (848592d) with master (e511cfd)1

Summary

✅ 14 untouched

Footnotes

  1. No successful run was found on master (ef1449d) during the generation of this report, so e511cfd was used instead as the comparison base. There might be some changes unrelated to this pull request in this report.

@bernardobelchior bernardobelchior force-pushed the heatmap-zoom branch 2 times, most recently from 7b39ace to 70586a2 Compare December 19, 2025 13:53
@bernardobelchior bernardobelchior marked this pull request as ready for review December 19, 2025 14:11

const seriesData: HeatmapValueType[] = [];

let max = 0;
Copy link
Member

Choose a reason for hiding this comment

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

Nitpick

Suggested change
let max = 0;
let maxContribution = 0;

Comment on lines +146 to +166
function HeatmapCell({
ownerState,
x,
y,
width,
height,
...props
}: HeatmapCellProps) {
return (
<rect
x={x + 1}
y={y + 1}
width={width - 2}
height={height - 2}
{...props}
rx={4}
ry={4}
fill={ownerState.color}
/>
);
}
Copy link
Member

Choose a reason for hiding this comment

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

I assume this is used to improve performances by removing highlight hooks

Copy link
Member Author

@bernardobelchior bernardobelchior Dec 19, 2025

Choose a reason for hiding this comment

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

No, it was just so we could have rounded corners and some padding 😅

useChartCartesianAxis,
useChartHighlight,
useChartProExport,
useChartBrush,
Copy link
Member

Choose a reason for hiding this comment

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

Are the brush necessary?

If yes, we should also add the <ChartsBrushOverlay />

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, it's necessary because the zoom plugin has a dependency on it. I can add checks and make it optional, but wouldn't it be better to add the brush overlay instead?

Copy link
Member Author

Choose a reason for hiding this comment

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

Added 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

scope: charts Changes related to the charts. type: new feature Expand the scope of the product to solve a new problem.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[charts-pro] Zoom support on heatmaps

3 participants