Redefined chart library built with React and D3
Some more small changes/fixes while working on 3.x
Legend
: fix issue where Legend was not taken into account when scaling the chart container by @zhonglin94 in https://github.com/recharts/recharts/pull/4272 closes https://github.com/recharts/recharts/issues/4246
Area
: fixed a bug where className was not assigned to areaDot by @108yen in https://github.com/recharts/recharts/pull/4294 closes https://github.com/recharts/recharts/issues/4290
RadialBar
: address regression where radial bar and its background were off from eachother because of rounding by @ckifer in https://github.com/recharts/recharts/pull/4295 closes https://github.com/recharts/recharts/issues/4264
ErrorBar
: do not count null
as 0 in error bar domain by @rinkstiekema in https://github.com/recharts/recharts/pull/4297
Full Changelog: https://github.com/recharts/recharts/compare/v2.12.2...v2.12.3
Some more small fixes while working on 3.x
Pie
: pie label keys are not unique when data is 0 by @ckifer in https://github.com/recharts/recharts/pull/4224
ResponsiveContainer
: Remove incorrectly timed console.warn call, only log when using soon-to-be deprecated feature by @HHongSeungWoo in https://github.com/recharts/recharts/pull/4249
Full Changelog: https://github.com/recharts/recharts/compare/v2.12.1...v2.12.2
Unintentional regression broke panoramic/compact Brush in 2.11.0 and 2.12.0, backport the fix to 2.x as we work on 3.x
Full Changelog: https://github.com/recharts/recharts/compare/v2.12.0...v2.12.1
Bug fixes and a few small new features.
Releasing 2.12.0 to create a "clean slate" as contributors are discussing next moves for recharts.
We will try to focus on upgrades, architectural changes, and long-pending breaking changes so we can release a recharts v3. This will not be a large major version, or one hard to upgrade to, but rather a major version bump to prevent us from breaking people with library upgrades, large refactors, etc. Feature parity should hold. Thanks!
Bar
: Accept a callback function for minPointSize
so it can be determined by data by @ckifer in https://github.com/recharts/recharts/pull/4099 closes https://github.com/recharts/recharts/issues/2819
Accessibility
: Enable screen reader support with accessibilityLayer and default tooltip by @julianna-langston in https://github.com/recharts/recharts/pull/4077
Bar
: activeBar
should not be true by default, fixes a breaking change from 2.9.0 by @ckifer in https://github.com/recharts/recharts/pull/4139 - fixes https://github.com/recharts/recharts/issues/4103 and https://github.com/recharts/recharts/issues/4101
Scatter
: fix non-unique key errors by @imagineLife in https://github.com/recharts/recharts/pull/4087 - fixes https://github.com/recharts/recharts/issues/4151 and https://github.com/recharts/recharts/issues/4060
Pie
: fix non-unique key errors by @imagineLife in https://github.com/recharts/recharts/pull/4106
Tooltip
: fix bug that caused throttled tooltip to stay active when moving mouse quickly by @HHongSeungWoo in https://github.com/recharts/recharts/pull/4100 fixes https://github.com/recharts/recharts/issues/4093
translateStyle
, remove prop-types as a peerDep
Full Changelog: https://github.com/recharts/recharts/compare/v2.11...v2.12.0
A special release: Containing a new chart type - SunburstChart by @csdiehl. Some behaviour might not yet align with the rest of the recharts components and API, we will improve it as (and if) issues come up. Thank you!
Secondly, I want to call out the work that @PavelVanecek is doing. We are slowly moving forward to improve our state management, using react context, and moving away from cloning components. While there still is a long way to go, I can not stress enough how important this refactoring is, both to the maintainability and extensibility of recharts. Great work!
Finally, we are continuously extending the Tooltip and enabling to control the Tooltip from the outside. With the work of @julianna-langston, we can now set the index for which to show a Tooltip. Further, we can now show the Tooltip for hidden elements.
POTENTIALLY BREAKING CHANGE: this release adds the use of the React context API which was not released until React 16.8. This means that 2.11 effectively drops support for React <16.8 unintentionally. Please report any breaking changes by making an issue.
Sunburst
: new chart type by @csdiehl in https://github.com/recharts/recharts/pull/4037
Accessibility
: Enable developers to specify tooltip position before users interact by @julianna-langston in https://github.com/recharts/recharts/pull/4070
Tooltip
: Enable showing hidden graphicalItems in Tooltip by @nikolasrieble in https://github.com/recharts/recharts/pull/4083
ErrorBar
: will now throw an invariant if X direction is used without type number
on axis by @AnujSharma141 in https://github.com/recharts/recharts/pull/4042
Radar
: allow events to be passed successfully to the Radar dot by @AnujSharma141 in https://github.com/recharts/recharts/pull/4056
TypeScript / Tooltip
: Payload
type now correctly includes className
by @Nikhilh26 in https://github.com/recharts/recharts/pull/4069
Accessibility
: fix bug causing accessibilityLayer
to break keyboard nav by @dahlie in https://github.com/recharts/recharts/pull/4079
Full Changelog: https://github.com/recharts/recharts/compare/v2.10...v2.11
Fix some older bugs annoying bugs, TS typings, update to the storybook theme, and more
ResponsiveContainer
: fix ref.current.current
without breaking users using current implementation by @HHongSeungWoo in https://github.com/recharts/recharts/pull/4008 - closes https://github.com/recharts/recharts/issues/3718
Brush
: Allow Brush to be controlled with start and end index via state by @ckifer in https://github.com/recharts/recharts/pull/4034 - closes https://github.com/recharts/recharts/issues/2404
Legend
: TypeScript - Add the dataKey type to legend props by @HHongSeungWoo in https://github.com/recharts/recharts/pull/4035 - closes https://github.com/recharts/recharts/issues/2909
Pie
: TypeScript - added payload
to PieSectorDataItem
type by @PavelVanecek in https://github.com/recharts/recharts/pull/4030
Pie
: unique sector keys fix by @imagineLife in https://github.com/recharts/recharts/pull/4009 closes https://github.com/recharts/recharts/issues/3273
RadialBar
: allow className to be passed to Radial Bar background by @ckifer in https://github.com/recharts/recharts/pull/4027 - closes https://github.com/recharts/recharts/issues/4011
Full Changelog: https://github.com/recharts/recharts/compare/v2.10.3...v2.10.4
key
bug(s) by @imagineLife in https://github.com/recharts/recharts/pull/4006 - closes https://github.com/recharts/recharts/issues/4004
Full Changelog: https://github.com/recharts/recharts/compare/v2.10.2...v2.10.3
Patch some bugs from 2.9 / 2.10
Tooltip
: Fix tooltip rendering crash when activeItem is undefined by @tran-simon in https://github.com/recharts/recharts/pull/3982
Cursor
: should no longer show gray background on hover where there was none previously @HHongSeungWoo in https://github.com/recharts/recharts/pull/3992
Tooltip
: show tooltip when data
prop is on individual cartesian component by @HHongSeungWoo in https://github.com/recharts/recharts/pull/3988
LabelList
- TypeScript: LabelList offset prop issue by @ckifer in https://github.com/recharts/recharts/pull/3999
Brush
: set default aria-label and allow value override by @enriquetamames-cpi in https://github.com/recharts/recharts/pull/3950
Full Changelog: https://github.com/recharts/recharts/compare/v2.10.1...v2.10.2
Both @HHongSeungWoo and @bernardobelchior landed improvements to performance!
getStringSize
when calculating visible ticks (#2589) by @bernardobelchior in https://github.com/recharts/recharts/pull/3953
We have made progress on our preparation of the 3.0 version by migrating from jest to vite. For details and motivation, please read the issue linked to the PR. Special thanks to @branberry for pushing on vitest! Thank you.
dataKey
prop on CategoricalChartProps
by @charpeni in https://github.com/recharts/recharts/pull/3870
Full Changelog: https://github.com/recharts/recharts/compare/v2.9.0...v2.10