Skip to content

2.0.0-beta2

Pre-release
Pre-release
Compare
Choose a tag to compare
@etimberg etimberg released this 28 Dec 13:33

The beta 2 release of Chart.js 2.0 adds support for chart titles and on canvas legends. Improved support for Asynchronous Module Definition and Common JS was added. Documentation for version 2 is available at http://nnnick.github.io/Chart.js/docs-v2/

Breaking API Changes

scale.ticks.minRotation was removed as it was not used.

Features

Legend and Title Block

Chart titles can now be added. An on canvas legend is enabled by default. Clicking or tapping on an item in the legend will toggle the visibility of the appropriate item in the chart.

UMD Build

Added a build step to add UMD headers via gulp-umd. These headers support AMD loaders such as requireJS, CommonJS modules, and falling back to the global context.

Bug Fixes

  • Allow formatting time scale values for the tooltip using a config option (#1466)
  • Gracefully handle setting options.animation = false (#1576)
  • Updated documentation for polar area and doughnut charts. Created documentation on extending Chart.js (#1582)
  • Time scale can now support multiples of base units (#1598 and #1717).
  • Highlight correct items when hoverMode is set to 'dataset' (#1706)
  • Removed unused tooltip options (#1710)
  • Actually call animation callbacks + created sample file (#1711)
  • Fixed rotational animation of new arc segments (#1715)
  • Tooltip breaks on max bar value (#1716)
  • beginAtZero option was disabled after running update() (#1725)
  • Removed unused minRotation option. (#1728). Thanks @npsecoding
  • Tooltips are sometimes truncated (#1731)
  • Fixed tooltip beforeBody and afterBody hooks (#1735)
  • Incorrect size of tooltip if beforeBody or afterBody was extremely long. (#1737)
  • Cleaned up issues found by CodeClimate (#1749 & #1756)
  • Handle setting a bezier curve tension to 0 (#1762)
  • Allow setting hard min and max limits for scales. (#1767) Thanks @olyckne
  • Fixed NPM package name with upper case letters (#1770)
  • Better detection of bars to handle custom bar extensions (#1785). Thanks @xriss
  • Fixed scope inside of new UMD wrapper. (#1795). Thanks @xriss
  • Scale label rotation test was off by 1. (#1797) Thanks @xriss
  • Allow disabling the label auto-skipper. (#1800) Thanks @olyckne
  • Fixed documentation error regarding tooltip padding. (#1802). Thanks @akagroundhog
  • Fix checking for ticks.suggestedMin is 0. (#1814). Thanks @hallatore
  • Ensure that cloning ticks in the time scale when there is no data works. (#1815). Thanks @hallatore
  • Refactored scale label auto skip functionality to use longest label. (#1816) Thanks @hallatore
  • Update documentation to fix incorrect code. (#1817). Thganks @prashcr
  • Removed bezier curve artifacts when tension is set to 0. (#1826). Thanks @hallatore
  • Use new padding option in auto skipper. (#1827). Thanks @hallatore
  • Prefer ticks.min over ticks.suggestedMin and ticks.max over ticks.suggestedMax (#1832). Thanks @hallatore