fix(deps): update dependency recharts to v3
This PR contains the following updates:
| Package | Change | Age | Confidence |
|---|---|---|---|
| recharts | 2.15.4 -> 3.6.0 |
Release Notes
recharts/recharts (recharts)
v3.6.0
What's Changed
3.6 🚀 - check out BarStack and ranged stacked bars 📊
Feat
-
BarStack: new componentBarStackby @​PavelVanecek in #​6746- allows configuring settings for the whole stack of bars such as
radius
- allows configuring settings for the whole stack of bars such as
-
Bar: enable ranged stacked bars by @​PavelVanecek in #​6722 -
Pie/Typescript: ExportPieSectorShapePropstype forshapefunction by @​ramanverse in #​6706XAxis/YAxis: Implement 'equidistantPreserveEnd' interval option for XAxis and YAxis (#​6642) by @​Om-Mishra09 in #​6661 -
Tooltip: AddgraphicalItemIdto tooltip payload object by @​PavelVanecek in #​6765 -
TypeScript: ExportTooltipIndex,BarRectangleItem,TreemapNode,DataKey,AxisIntervalfrom public API by @​Copilot in #​6676
Fix
-
Scatter: fix bug where Tooltip payload data was duplicated or contained unrelated items when using multipleScatterelements in oneScatterChartby @​PavelVanecek in #​6773 -
Label/LabelList:Fix crash whenLabelis passed as content toLabelListby @​Harikrushn9118 in #​6732 -
General: Round numbers before putting them to DOM by @​PavelVanecek in #​6707 -
General: Store refs instead of IDs to unblock shadow DOM usecases by @​PavelVanecek in #​6753
Chore
-
CartesianAxis: DeprecateCartesianAxis@​PavelVanecek in #​6774 - Bump to Node 24
- Lots of
undefinedchecks for progress towards TSstrictmode
Docs
- Docs should be improving on the daily - comments in code + storybook + the website should all be coming closer to in sync thanks to @​PavelVanecek pretty much writing his own documentation generator 🤖 🚀
New Contributors
- @​Om-Mishra09 made their first contribution in #​6661
- @​taro-yanagiya made their first contribution in #​6708
- @​ramanverse made their first contribution in #​6706
- @​Advikkhandelwal made their first contribution in #​6714
- @​Harikrushn9118 made their first contribution in #​6732
- @​milanchahar made their first contribution in #​6739
Full Changelog: https://github.com/recharts/recharts/compare/v3.5.1...v3.6.0
v3.5.1
What's Changed
Fix
-
Pie: add missingSectorindex toPieshapeprop by @​ckifer in #​6683- This enables customization of specific slices of the
Piesimilar toactiveIndexin 2.x
- This enables customization of specific slices of the
-
Pie: prevent cross-Pie highlighting in multi-PiePieCharts with shared dataKeys by @​shreedharbhat98 in #​6678- Only marks a specific Sector as active when that sector is hovered
-
TypeScript/Tooltip: updateactiveLabeltype to be astring | numberby @​ckifer in #​6691- !! NOTE !!: This change may break your types if you relied on it as a string, but this is a bug fix
-
Accessibility/General: addtabIndex-1 on RechartsZIndexsvg portalgtags to prevent extraneous focusable surfaces by @​ckifer in #​6687 -
General: Removed accidental eslint dependency from main dependencies which should remove it from installation with recharts
New Contributors
- @​Ashish-rajput999 made their first contribution in #​6694
Full Changelog: https://github.com/recharts/recharts/compare/v3.5.0...v3.5.1
v3.5.0
What's Changed
Mostly fixes and performance improvements this release but check out the deprecation of Pie active/inactiveShape in favor of aligning with the shape prop of other chart elements.
Feat
-
Pie: addshapeto align custom Pie sector shapes to other Recharts components by @​ckifer in #​6482- This change deprecates
activeShapeandinactiveShape. Please use theisActiveprop passed from the callback toshapeto create active Pie sectors. - Note: forgot to include the current Sector index, will add in 3.5.1
- This change deprecates
-
Stacked Charts: implementreverseStackOrderprop in v3 - fixes a regression between recharts 2 and 3 by @​j-shimizu111 in #​6644 -
Typescript/Dot: exportActiveDotPropsandDotItemDotPropstypes by @​simaks in #​6657
Fix
- Performance Improvements! https://recharts.github.io/en-US/guide/performance/
-
- Optimize
SetTooltipEntrySettingsto break infinite rendering loop by @​PavelVanecek in #​6616
- Optimize
- Various performance improvements by @​PavelVanecek in #​6634
- Some more performance improvements by @​PavelVanecek in #​6654
-
-
Line: fix animation when interrupted with non-data related changes by @​PavelVanecek in #​6641 -
Line/Area: fix active dot appearing outside graph by @​cameronm-orion in #​6612 -
Legend: aLegendwith aportalno longer adjusts the margin of the chart (which left an empty space) by @​ckifer in #​6609 -
ErrorBar: remove duplicate key warning when error range has same values by @​bas0N in #​6660 -
PolarAngleAxis: prevent overlapping "0" and "360" ticks by @​PavelVanecek in #​6611 -
Typescript/Area: add specific type toArea.labelinstead ofanyby @​PavelVanecek in #​6621 -
General: disable immutable check in production, removes console warnings by @​tngwoerleij in #​6619
Docs
- Add guide for performant charts by @​PavelVanecek in #​6659
- https://recharts.github.io/en-US/guide/performance/ please follow the guide for best results
- @​PavelVanecek fixed and updated a lot of our documentation on both the storybook and website 📖 🚀
New Contributors (thanks everyone!)
- @​Parth10P made their first contribution in #​6623
- @​j-shimizu111 made their first contribution in #​6644
- @​tngwoerleij made their first contribution in #​6619
- @​bas0N made their first contribution in #​6660
- @​cameronm-orion made their first contribution in #​6612
- @​simaks made their first contribution in #​6657
Full Changelog: https://github.com/recharts/recharts/compare/v3.4.1...v3.4.2
v3.4.1
What's Changed
Forgot some exports for Z Index in 3.4
- export
DefaultZIndexesandZIndexLayerby @​ckifer in #​6599
Full Changelog: https://github.com/recharts/recharts/compare/v3.4.0...v3.4.1
v3.4.0
v3.3.0
What's Changed
Feat
-
ResponsiveContaineris now built-in to all charts by @​PavelVanecek in #​6388- add the
responsiveprop to any chart along with a height and width as if you were usingResponsiveContainer. One less component to wrap things with.ResponsiveContainerwill continue to work for the life of 3.x
- add the
<BarChart data={data} responsive height={300} width="100%">
....
</BarChart>
Fix
-
YAxis: Only use the YAxiswidth="auto"oscillation detection if the difference is > 1 pixel by @​PavelVanecek in #​6450 -
ResponsiveContainer: only shrinks in the dimensions where it needs to shrink by @​PavelVanecek in #​6367 -
Treemap: fix animation stutters in Treemap by @​PavelVanecek in #​6326 -
Sankey: fix unique key error by @​daiboom in #​6352
Website changes - https://recharts.github.io/
- Recharts website is now inlined in recharts/www as opposed to https://github.com/recharts/recharts.org
- NEW recharts website URL at https://recharts.github.io/
Unfortunately the current contributors and admins do not own recharts.org and the renewal of the domain remains up in the air. To remove that uncertainty we have deployed the website at our github pages URL instead.
New Contributors
- @​kristiandueholm made their first contribution in #​6344
- @​daiboom made their first contribution in #​6352
- @​vmizg made their first contribution in #​6387
Full Changelog: https://github.com/recharts/recharts/compare/v3.2.1...v3.3.0
v3.2.1
What's Changed
Fix
-
X/YAxis, etc.: reduce re-renders to fix blinking line in Zoom & Highlight example by @​PavelVanecek in #​6315 -
Bar: Remove redundantRectangleimport, fixes tsup builds with recharts in them by @​guscost in #​6305 -
Pie: fix PieLabel types by @​PavelVanecek in #​6313 -
Brush: fix index off by one error whenmarginis 0 by @​ckifer in #​6323 - Enable dev tools via Global module instead of window by @​uncaught in #​6309
New Contributors
- @​guscost made their first contribution in #​6305
Full Changelog: https://github.com/recharts/recharts/compare/v3.2.0...v3.2.1
v3.2.0
What's Changed
Quite a bit of 3.0 bug fixes in this release along with two new hooks. Thanks to all who've been reporting issues!
Feat
-
Pie: support string values in PieouterRadiuscallbacks by @​rephaelberkooz in #​6191 -
PolarGrid: addfillcolor support to by @​mindtraveller in #​6287
Hooks
-
New :
useXAxisDomainanduseYAxisDomainhooks by @​PavelVanecek in #​6201 -
New:
useMarginhook by @​PavelVanecek in #​6224
Fix
-
Bar: fix unnecessary line breaks in Bar labels by @​eino in #​6214 -
Bar: improveBarperformance whenactiveBaris turned off by @​PavelVanecek in #​6290 -
Stacked Bar/Area: fix stacked charts with duplicate categorical data by @​PavelVanecek in #​6194 -
Scatter: fix exception when Scatter data has non-stringtypeproperty by @​PavelVanecek in #​6248 -
X/YAxis: fix blinking when changing props by @​PavelVanecek in #​6262 -
PolarAngleAxis/Radar: fix polar angle axis ticks text positions by @​mindtraveller in #​6276 -
Label: allow rendering Labels as nested children inXAxis,YAxisand Reference elements by @​PavelVanecek in #​6219LabelList: fix issue with LabelList not rendering inPiecharts by @​PavelVanecek in #​6246 -
Text: fix exception whenText's children is empty and scaleToFit=true by @​PavelVanecek in #​6282 -
Tooltip: bound Tooltip coordinates to the chart container in synchronized charts by @​shreedharbhat98 in #​6263 -
Brush:allow brush travelers to be controlled by keys after mouse interaction by @​ckifer in #​6285 -
useActiveTooltipDataPoints: fix infinite rendering loop by @​PavelVanecek in #​6247
Chore
- Upgrade to ESLint 9 by @​NishargShah in #​6284
- Add better storybook docs for Text component by @​PavelVanecek in #​6278
- Make Recharts Redux devTools registration opt-in (fixes #​6250) by @​uncaught in #​6264
- Continued refactoring/improvements by @​PavelVanecek 🚀
New Contributors (thanks everyone!)
- @​rephaelberkooz made their first contribution in #​6189
- @​uncaught made their first contribution in #​6264
- @​mindtraveller made their first contribution in #​6276
- @​NishargShah made their first contribution in #​6284
Full Changelog: https://github.com/recharts/recharts/compare/v3.1.2...v3.1.3
v3.1.2
What's Changed
Fix
-
Label/Polar Charts:Labelviewbox should now be present in polar charts and address #​6030 by @​PavelVanecek in #​6180 - Add LRU cache for string size measurements (#​3955) by @​shreedharbhat98 in #​6176
Full Changelog: https://github.com/recharts/recharts/compare/v3.1.1...v3.1.2
v3.1.1
What's Changed
Fix
-
General: Don't apply duplicate IDs in the DOM by @​PavelVanecek in #​6111 -
Stacked Area/Bar: give all graphical items their own unique identifier and use that to select stacked data. Fixes issue where stacked charts could not be created from the graphical itemdataprop #​6073 by @​PavelVanecek -
Stacked Area/Bar: exclude stacked axis domain when not relevant for axis by @​rinkstiekema in #​6162 fixes issue where numeric stacked charts would not render correctly -
Area Chart: ranged area chart - show active dot on both points instead of just the top one by @​sroy8091 in #​6116 fixes #​6080 -
Polar Charts/Label: fixLabelin polar charts by @​PavelVanecek in #​6126 -
Scatter/ErrorBar: choose implicit Scatter ErrorBar direction based on chart layout (to be the same as 2.x) by @​PavelVanecek in #​6159 -
X/YAxis/Reference Components: allow axis values and reference items to render when there is no data but there is a domain/explicit ticks set by @​ethphan in #​6161 -
X/YAxis: pass axis padding info to custom tick components by @​shreedharbhat98 in #​6163
Chore / Testing
- good progress on our journey to enable
strictNullChecks - addition of playwright visual regression tests to CI
- split
AnimateintoJavascriptAnimateandCSSTransitionAnimateby @​PavelVanecek in #​6175
New Contributors
- @​sroy8091 made their first contribution in #​6116
- @​ethphan made their first contribution in #​6161
Full Changelog: https://github.com/recharts/recharts/compare/v3.1.0...v3.1.1
v3.1.0
What's Changed
Bug fixes (old and new) and a few new hooks post 3.0 launch!
Feat
More hooks!
- Add
useOffsetandusePlotAreahooks by @​PavelVanecek in #​6057 - Add
useActiveTooltipDataPointshook by @​PavelVanecek in #​6067
Fix
-
Legend: After hiding and showing legend elements, keep them in the same order as before by @​PavelVanecek in #​6026 -
Bar: addpayloadas a valid property onBarRectangleItemby @​ckifer in #​6029 -
Accessibility: Removerole=applicationfrom recharts wrapper (this was removed in 2.x for accessibility reasons) by @​PavelVanecek in #​6060 -
ResponsiveContainer: Addoverflow: visiblezero-size wrapper so that ResponsiveContainer can shrink by @​PavelVanecek in #​6068 -
X/YAxis: FixtickCountandallowDecimalsif axis domain does not include the keyword 'auto' by @​PavelVanecek in #​6070 -
Tooltip: Fix active tooltip and dots when there are multiple graphical items each with their own data by @​PavelVanecek in #​6074
Docs
- Our storybook stories can now open in stackblitz by @​PavelVanecek in #​6043
- Add hook inspector documentation by @​PavelVanecek in #​6059
Chore
- Remove duplicate 'square' from Pie component’s legendType summary by @​davinahi in #​6054
New Contributors
- @​davinahi made their first contribution in #​6054
Full Changelog: https://github.com/recharts/recharts/compare/v3.0.2...v3.1.0
v3.0.2
What's Changed
Please skip 3.0.1 and go straight to 3.0.2 - #​6022. In React.StrictMode charts in 3.0.1 were not rendering at all. This revert should resolve that.
-
revert: revert preserve legend order by @​ckifer in #​6023
Full Changelog: https://github.com/recharts/recharts/compare/v3.0.1...v3.0.2
v3.0.1
⚠️ Version 3.0.1 has a bug where some charts will not render in React strict mode. Please use 3.0.2 or higher. ⚠️
What's Changed
Lots of fixes from the 3.0 release - thanks for the reports!
Edit: broke something #​6022
Fix
-
Label: fix an issue which causedlabelRefto get passed to custom DOM elements which logged an error/warning by @​saurabhraj123 in #​6008 -
Pie->Label: fix issue where pie labels were not rendering correctly when specified as a child ofPieby @​PavelVanecek in #​5987 -
Legend: apply legenditemSorterfor customcontentas well as default content by @​PavelVanecek in #​6012 ~~*Legend: keep legend items in the same order when they are hidden and shown by @​PavelVanecek in #​6017~~ -
Bar->Brush: fix undefined access error when usingBrushwith stacked bar charts by @​PavelVanecek in #​6009 -
X/YAxis: fixDecimalErrorwhen creating vertical oriented charts with a single datapoint by @​ckifer in #​6016 -
X/Y/PolarAngle/PolarRadius Axis:tickFormatteris no longer called with data indexes before the actual data by @​PavelVanecek in #​6019
Full Changelog: https://github.com/recharts/recharts/compare/v3.0.0...v3.0.1
v3.0.0
🚀 Recharts 3 is here!
Huge shoutout to @​PavelVanecek who wrote 95% of the code for this major version release. We re-wrote recharts state management, wrote some 3500 unit tests, fixed a bunch of bugs, and added a few well-requested features.
The intent with 3.0 is that it is now a better/easier place for the community to contribute to. Looking forward to what the future of recharts looks like in 3.x and beyond!
More details and the 3.0 migration guide
BREAKING CHANGES
Please see https://github.com/recharts/recharts/wiki/3.0-migration-guide#breaking-code-changes
tldr;
-
CategoricalChartState(which was access to recharts internal state) no longer exists in event handlers orCustomized, etc. -
<Customized />no longer receives recharts state/props - Removal of internal props that were always supposed to only be internal to recharts
- Remove previously deprecated props
- ...see full list linked above
New Features
- Custom Components - you can now render any react component in the recharts tree structure (but it must still be renderable within an SVG). Previously this was controlled and filtered by recharts
- Tooltip Portals - you can now use portals to position your tooltip data anywhere you'd like, including outside of your chart
- Legend Portals - similar to the above, you can now use portals to position your Legend anywhere you'd like, including outside of your chart
-
Accessible by default -
accessibilityLayeris now on on all polar and cartesian charts by default. Tab into the chart and use the arrow keys to navigate. - Polar charts now support multiple axes (similar to cartesian charts)
- Tooltip: You can now select which axis your Tooltip belongs to using
axisId -
YAxis: auto width calculation for YAxes - setwidth="auto" -
X/YAxis: Addsymlogd3 scale type
Bug fixes and improvements
This release fixes some long standing issues in recharts, the easiest way to determine all of them is to take a look at the recharts 3.0 project board
- Animation improvements
- Typescript improvements
- Accessibility fixes/improvements
-
Pie: no more border around pie sectors on click, etc. -
CartesianGrid: background now renders below the grid lines instead of above - and more!
Our 3.0 storybook has a lot of updated examples!
Configuration
đź“… Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Enabled.
â™» Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
- [ ] If you want to rebase/retry this PR, check this box
This PR was generated by Mend Renovate. View the repository job log.