Skip to content

Version 2.7.0

Compare
Choose a tag to compare
@chartjs-ci chartjs-ci released this 10 Sep 17:31
· 2071 commits to master since this release

Version 2.7 brings better stability, and powerful new features to Chart.js. The bubble chart options are now completely scriptable. This means that you can pass a function to a bubble chart dataset property and have the function be called as needed. This simplifies array properties, and allows quick and easy rendering changes based on data values. Check out the sample for details. If these options prove useful, they can be extended to other chart types in the future.

Building off the time scale rewrite in version 2.6, the time scale now supports options for configuring how labels generate ticks, how interpolation between the points is handled and the scale boundary strategy. Users can now configure ticks to be generated for each label, or be determined automatically from the data limits. Users can also change how ticks are distributed along the axis] to make non-linear time axes. Check out the sample for details.

Documentation: http://www.chartjs.org/docs/2.7.0/

Breaking Changes

  • #4079 Doughnut, polarArea and radar charts aspect ratio changed to 2 to be consistent with other charts and are not square anymore by default. Use the aspectRatio: 1 option to restore the previous behaviour.

Deprecations

  • #4401 Deprecated time scale unitStepSize, use stepSize instead.

New Features

Enhancements

  • #4362 Add support for configurable update. Thanks @ricardocosta89
  • #4381 Scatter chart doesn't anymore display lines by default.
  • #4382 Add support for multiple lines text in the chart title.
  • #4531 Add support for line height CSS values.
  • #4545 New offset scale option. Thanks @nagix
  • #4586 Allow updating dataset types. Thanks @benmccann
  • #4591 Add support for detached canvas element.
  • #4596 Replace the IFRAME resizer by scrollable DIVs.
  • #4632 Ticks callback is now called with this as scope. Thanks @andig
  • #4708 Add platform fallback implementation.
  • #4733 Update chartjs-color dependency to version 2.2.0

Issues Fixed

  • #4079 Fixed inconsistent aspect ratio (2 for all charts). Thanks @jtblin
  • #4249 Fixed labelOffset not working for vertical axes. Thanks @suheb
  • #4295 Fixed missing IE *_SAFE_INTEGER constants. Thanks @OlduwanSteve
  • #4297 Fixed onHover event not being triggered. Thanks @ricardocosta89
  • #4318 Fixed disabled legend items alignment.
  • #4319 Fixed default layout options (empty object).
  • #4341 Fixed tooltip color box border width.
  • #4348 Fixed time scale round option.
  • #4360 Fixed filling between datasets of different lengths.
  • #4402 Fixed error when legend labels option is undefined.
  • #4403 ticks.padding option now applies to vertical and horizontal scales.
  • #4406 Ensured that chart dimensions are always >= 0. Thanks @Peter-Van-Drunen
  • #4424 Fixed non-passive event listener warning in Chrome.
  • #4425 Fixed range calculation when all datasets hidden and axis minimum set.
  • #4448 Radius is now clamped when drawing rounded rectangle.
  • #4451 Chart area is now clipped before filling.
  • #4457 Fixed reverse option in radial linear scale.
  • #4459 Line chart pointBorderWidth now supports array.
  • #4522 Honour time scale min/max settings. Thanks @andig
  • #4545 Make offsetGridLines consistent. Thanks @nagix
  • #4655 Removed redundant tooltip initialize. Thanks @xg-wang
  • #4682 Show radial scale labels correctly when rotated.
  • #4697 Fixed filling datasets when stepped line. Thanks @nagix

Documentation

Development

  • #4272 Upgraded development dependencies. Thanks @benmccann
  • #4346 Switched Travis to use Node 6. Thanks @benmccann
  • #4419 Cleaned up and reorganize core and canvas helpers.
  • #4421 Increased ESLint complexity and add config for tests.
  • #4422 Rewrote the clone and merge helpers.
  • #4423 Changed valueAtIndexOrDefault behavior.
  • #4427 Removed .js extensions when requiring a file. Thanks @let-aurn
  • #4475 Moved easing effects in separate file + unit tests.
  • #4477 Fixed many link anchors. Thanks @adrianliaw
  • #4479 Chart.helpers is now importable.
  • #4485 Fixed ESLint errors. Thanks @benmccann
  • #4509 Chart.platform is now importable.
  • #4512 Chart.defaults/Ticks/Interaction are now importable.
  • #4540 Chart.Element/elements.* are now importable.
  • #4542 Removed duplicate npm install. Thanks @benmccann
  • #4544 Refactored padding parsing in helpers.options.
  • #4547 Enforced spaces around infix/unary words operators.
  • #4566 Rewrote unit test waitForResize helper.
  • #4610 Enforced variable declaration coding style.
  • #4614 Refactored autoskip functionality into a separate method. Thanks @benmccann
  • #4617 Fixed tests on OSX with retina screen. Thanks @andig
  • #4654 Better CodeClimate integration.
  • #4698 Improved controller test stability. Thanks @andig

More details in the release PR: #4706