Skip to content

Releases: chartjs/Chart.js

Version 2.8.0

14 Mar 13:08
Compare
Choose a tag to compare

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

Deprecations

  • #5868 Deprecate Chart.{Type} classes
  • #6022 Deprecate configMerge and scaleMerge helpers

Enhancements

  • #5741 Add minBarLength option for bar chart. Thanks @adube
  • #5780 Bar options are now scriptable
  • #5841 Draw inner border for arc elements
  • #5850 Add support for gridLines/angleLines borderDash for polar area and radar charts
  • #5855 Moved drawing of radial lines before drawing the tick labels. Thanks @fhp
  • #5885 Add support for hiding axis when all datasets are hidden. Thanks @davesalomon
  • #5905 Add support for typed arrays
  • #5908 Add midpoint interpolation to stepped line. Thanks @veggiesaurus
  • #5927 Add reverse support to time scale
  • #5938 Improve tick generation for linear scales
  • #5951 New weight option for pie and doughnut charts
  • #5960 Implement adapter to abstract date/time features
  • #5966 Doughnut options are now scriptable
  • #5973 Line options are now scriptable
  • #5976 Polar area options are now scriptable
  • #5978 Make moment optional from our UMD builds
  • #5982 Remove date auto type conversions
  • #6019 Improve time scale performances
  • #6041 Radar options are now scriptable
  • #6048 Move CSS in a separate file to be CSP-compliant
  • #6059 Add onLeave callback to legend. Thanks @jonrimmer
  • #6077 Allow configuration of borderWidth as object
  • #6105 Optimize the npm package by removing useless files

Issues Fixed

  • #5331 Make animation duration consistent across browsers. Thanks @serhii-yakymuk
  • #5609 Fix offsetGridLine behavior with a single data point
  • #5750 Ensure that the time scale safely accesses data.labels
  • #5751 Handle axis lineWidth as an array
  • #5752 Ensure that new Number() is correctly handled
  • #5776 Fix legend layout padding at the start of columns. Thanks @jtagscherer
  • #5786 Support decimal stepSize
  • #5790 Add error margin for detecting if a point or line is in the chart area
  • #5816 Fix legend item layout issue
  • #5828 Improve shadow root detection. Thanks @karaxuna
  • #5846 Correct calculation of padding in percent. Thanks @chtheis
  • #5848 Fix radial scale topmost tick label and the bottom of the chart area that were cut off
  • #5857 Fix nearest interaction mode
  • #5858 Adjust the size of rectRounded/rectRot points to fit the circle with pointRadius
  • #5865 Support CanvasGradient for hover colors
  • #5869 Tooltip support for CanvasPattern and CanvasGradient
  • #5880 Fix the rounding issue of floating point numbers in category scale
  • #5884 Remove gaps on the left and right when the axis offset is set to true
  • #5891 Remove autoSkip logic to always display last tick. Thanks @sgray
  • #5909 Remove innerHTML usage from our DOM platform
  • #5913 Re-allow modifying ticks in afterBuildTicks
  • #5914 Add scale.pointLabels.lineHeight and scale.ticks.lineHeight options
  • #5920 Return correct label for value type axis
  • #5922 Properly calculate space needed by tick label when autoSkip is true
  • #5925 Align title, body and footer inside tooltip
  • #5933 Fix time scale ticks.reverse issue
  • #5936 Fix "RangeError" exception when labels are big (>125000). Thanks @ckyycc
  • #5937 Prevent Bezier points from being capped when a data point is off the chart
  • #5947 Cast getRightValue to number in bar chart
  • #5948 Fix ticks generation when working with tiny numbers
  • #5963 Fix fitWithPointLabels calculation in radial linear scale
  • #5996 Replace tooltip item xLabel and yLabel with label and value
  • #6006 Enhance legend label color point when usePointStyle is true. Thanks @alfiehd
  • #6007 Prevent drawing radial linear scale twice
  • #6008 Supply correct start parameter to insertElements
  • #6011 Prevent infinite resize when vertical scrollbar appears
  • #6021 Fix padding of horizontal axes when labels are rotated
  • #6027 Provide a rectangle getArea implementation for horizontal bars
  • #6046 Rename addEventListener and removeEventListener
  • #6058 Ignore invalid log scale min and max
  • #6060 Handle frozen dataset.data arrays
  • #6063 Fix responsive resize on RTL page

Documentation

  • #5756 Add documentation the aspectRatio property. Thanks @danielcb29
  • #5769 Use parser instead of the deprecated format option. Thanks @Niladri24dutta
  • #5795 Document tick padding option. Thanks @JEphron
  • #5796 Consistent use of punctuation. Thanks @bartdeslagmulder
  • #5813 Add a link to chartjs-plugin-colorschemes
  • #5831 Correct a spelling mistake. Thanks @bakert
  • #5854 Add docs for barThickness. Thanks @jedrekdomanski
  • #5876 Fix descriptions in bar chart doc
  • #5877 Replace repeated function call with compact function, generateData. Thanks @generic-github-user
  • #5912 Add omi-chart to the doc. Thanks @dntzhang
  • #5915 Use HTTPS in documentation links where possible
  • #5958 Use Chart.min.js in samples
  • #5962 Update contributors guide and issue templates
  • #5968 Fix contribution docs. Thanks @mojoaxel
  • #5974 Add a note about maintainAspectRatio. Thanks @janelledement
  • #5975 Fix typo / grammar in docs
  • #5979 Fix labelOffset description
  • #6013 Set pointBackgroundColor in radar sample
  • #6020 Fix typos and minor doc issues
  • #6026 Omit inconsistent note. Thanks @janelledement
  • #6030 Update doc on label types for TooltipItem
  • #6038 Fix duplicate anchor
  • #6042 Add examples of scriptable charts. Thanks @janelledement
  • #6053 Fix typo in broken url. Thanks @janelledement
  • #6054 Simple spelling error fix. Thanks @JABedford
  • #6070 Add a link to chartjs-plugin-crosshair. Thanks @AbelHeinsbroek
  • #6073 Add instructions for image-based tests to the contributors guide
  • #6079 Improve autoSkip documentation
  • #6081 Add a link to chartjs-plugin-rough
  • #6089 Improve financial sample tooltips and interactions
  • #6096 Revamp the README.md and add link to the awesome list
  • #6099 Fix document errors related to ticks
  • #6107 Add a note about how to include an example against master

Development

  • #5624 Radar code cleanup
  • #5777 Support *.js test fixture configs
  • #5794 Remove dead code from the gulpfile. Thanks @HendrikRoehm
  • #5827 Change .editorconfig file to include newlines at EOF. Thanks @jtagscherer
  • #5833 Use the pixel comparer for logarithmic tests. Thanks @jtagscherer
  • #5840 Upgrade dev dependencies to reduce vulnerabilities
  • #5842 Use short labels for the legend tests so as not to be affected by the font width
  • #5871 Make Chart.controllers.* importable
  • #5872 Fix test failures on Windows
  • #5875 Remove gulp-connect and add jsdelivr/unpkg paths
  • #5904 Migrate from Browserify to rollup
  • #5953 Cleanup scales export for better import strategy
  • #5965 Refactoring using helpers.options.resolve
  • #5967 Update controller.scatter.test.js to test default tooltip callbacks. Thanks @Madrussian
  • #5969 Make the main controller importable
  • #5970 Remove unused parameter when calling removeResizeListener. Thanks @DanielRuf
  • #5991 Trigger mouse events at the center of arc
  • #5994 _resolveElementPoint utility for triggerMouseEvent
  • #6005 Common logic for resolving element options
  • #6017 Fix typo in comment
  • #6032 Replace deprecated gulp-util and remove unused watchify
  • #6033 Use lowercase for primitives in jsdocs
  • #6040 Remove unused ESLint directive
  • #6043 Autoskip cleanup
  • #6061 Fix randomly failing tooltip test

Thanks to the maintainers and collaborators for their help to improve and test Chart.js (@nagix, @kurkle, @benmccann, @etimberg and @simonbrunel).

More details in the release PR: #6092

v2.8.0-rc.1

04 Mar 12:31
Compare
Choose a tag to compare
v2.8.0-rc.1 Pre-release
Pre-release
Version 2.8.0-rc.1

Version 2.7.3

15 Oct 17:21
Compare
Choose a tag to compare

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

Enhancements

  • #4841 Add ticks.precision option to linear scale
  • #5279 Added 'angle' option to Polar Charts. Thanks @slinhart
  • #5319 Enable arbitrary rotation of datapoints. Thanks @joelhamilton5
  • #5324 Enable running on virtual canvas on node. Thanks @SeanSobey
  • #5363 Skip point outside the clipping area. Thanks @veggiesaurus
  • #5521 Handle '\n' as new line in tooltips. Thanks @CWSites
  • #5585 Add support for Shadow DOM. Thanks @reda-alaoui
  • #5592 Call update() and render() with a config object. Thanks @nagix
  • #5597 Enhance the rounded rectangle implementation
  • #5613 Add 15 minutes time steps. Thanks @fenichelar
  • #5623 Refactor helpers.canvas.drawPoint(). Thanks @nagix

Issues Fixed

  • #4620 Fixed responsive in IE11 with padding as percentage. Thanks @andi-b
  • #5172 Avoid updating Chart when responsive: true and Chart is hidden. Thanks @jcopperfield
  • #5209 Fixed min and max option checks in linear scales. Thanks @teroman
  • #5321 Fixed line clipping at the chart area borders. Thanks @serhii-yakymuk
  • #5401 Proper tick position for right positioned axis
  • #5570 Restore original styles when removing hover
  • #5575 Event handling to use target instead currentTarget. Thanks @teroman
  • #5723 Fixed scale when data is all small numbers. Thanks @costerwi

Documentation

Development

  • #5382 Make Chart.Animation/animations/Tooltip importable
  • #5383 Make Chart.Scale/scaleService importable
  • #5478 Update gulpfile.js to use in strict mode. Thanks @ksokolowski7
  • #5595 Use comment for pull request template Thanks @DanielRuf
  • #5629 Disable hardware acceleration for unit tests
  • #5724 Add gulp watch task for docs @wuweiweiwu
  • #5732 Add "point style" image tests

More details in the release PR: #5732

Version 2.7.2

01 Mar 21:51
Compare
Choose a tag to compare

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

Enhancements

  • #4891 Relax dependencies versions. Thanks @jsg2021
  • #4923 Reset only when animating (optimization)
  • #4994 Equally sized bars for bar charts
  • #5062 Improve point.xRange and point.yRange performance. Thanks @fanthos
  • #5076 Prevent double ticks array reverse for logarithmic scale (optimization). Thanks @jcopperfield
  • #5095 Better default tooltip label format in the time scale
  • #5240 Support multiple font colors for radial chart labels. Thanks @flaurida

Issues Fixed

Documentation

Development

  • #4699 Suppress coveralls errors in forks. Thanks @andig
  • #4738 Upgrade to ESLint 4
  • #5053 Update license year and copyright holders
  • #5112 Use the Chart.js shared ESLint config
  • #5113 Make Chart.layout(Service) importable
  • #5114 Make Chart.plugins importable
  • #5118 Rename Chart.layout to Chart.layouts
  • #5138 Ignore package-lock.json
  • #5143 Log gulp error. Thanks @loicbourgois
  • #5150 Test for showLines in scatter chart. Thanks @loicbourgois
  • #5195 Setup HTML and JS linters for samples. Thanks @loicbourgois
  • #5217 Fix Slack invitation link

More details in the release PR: #5145

Version 2.7.1

28 Oct 15:10
Compare
Choose a tag to compare

2.7.1 is a bug fix release and also includes numerous documentation improvements

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

Enhancements

  • #4793 Added beforeTooltipDraw and afterTooltipDraw to plugins. Thanks @JewelsJLF

Issues Fixed

  • #4295 Fixed min and max in time scale
  • #4762 Fixed regression in x-axis interaction mode
  • #4774 Fixed chart responsiveness
  • #4779 Fixed unit used for auto ticks in time scale
  • #4781 Fixed handling of null style. Thanks @Rydori
  • #4783 Fixed color settings for BeforeLabel and BeforeBody. Thanks @Rittyan
  • #4795 Fixed handling of null labels
  • #4878 Fixed rollup issue caused by early access of the extend and inherits helpers
  • #4840 Fixed tooltip reset

Documentation

  • #4736 Expand scale jsdocs
  • #4765 Consistent formatting for cartesian options
  • #4818 Update supported browser section of documentation
  • #4819 Typo in code comments. Thanks @einfallstoll
  • #4826 Clarification for using x/y coordinates with bar chart
  • #4851 Improved rendering of tables describing options. Thanks @minusf

Development

  • #4880 Address test flakiness

More details in the release PR: #4876

Version 2.7.0

10 Sep 17:31
Compare
Choose a tag to compare

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

Version 2.6.0

25 May 14:01
Compare
Choose a tag to compare

Version 2.6 brings better stability, improved documentation, and powerful new features to Chart.js. It's now possible to create advanced area chart thanks to a new filler plugin: stacked area charts can now fill to another dataset in a configurable manner. Check out the samples to see the all the new options.

The time scale internals have been rewritten, improving performance by reducing the number of operations on each tick value. These changes also fixed a number of time scale related issues that users have been experiencing.

Our new documentation has been rewritten using GitBook and reorganized into smaller topics to improve clarity and allow topics to be more intuitively found. The online documentation is now organized by release version going forward: http://www.chartjs.org/docs/{version}/.

Breaking Changes

  • #3782 The lineArc setting for the radial linear scale has been removed and replaced by gridLines.circular and pointLabels.display.
  • #4044 The bar controller internals has been refactored, therefore custom chart types that extend from the bar controller will need to be updated. More details can be found in this PR.

Deprecations

  • #3839 Chart.chart has been merged in Chart.
  • #3839 Chart.Controller has been merged in Chart.
  • #3959 Chart.Animation.animationObject has been merged in Chart.Animation.
  • #3959 Chart.Animation.chartInstance has been removed, use Chart.Animation.chart instead.
  • #4008 'zero', 'top', 'bottom' fill modes has been replaced by 'origin', 'start', 'end'.

New Features

  • #3599 New option to control the tooltip caret padding.
  • #3782 New option to handle displaying point labels on a radar chart.
  • #3782 New option to control if the lines appear as circles or straight lines.
  • #3812, #4094 Layout service now supports item ordering (item.weigth).
  • #3872 Added support for drawing tooltip borders. Thanks @marcelotedeschi
  • #3926 Added dataset update and draw plugin hooks.
  • #3963 Max bar thickness is now configurable. Thanks @seven7seven
  • #4008 Added support to fill between datasets.
  • #4019 New option for dashed 0 lines on axes. Thanks @lndobryden
  • #4065 Added before and after functionality to the steppedLine option. Thanks @ericnkatz

Enhancements

  • #2043 Added documentation for high performance charting.
  • #2325 Updated documentation for extending chart types.
  • #2362 Added documentation for multi-chart and multi-axis.
  • #2386 Updated documentation for custom tooltips implementation.
  • #3274, #3299 Improved documentation on axis range settings.
  • #3662 Added documentation for extending scales.
  • #3751 Documentation has been fully rewritten and is now based on Gitbook.
  • #3826 Improved performance for time scale label parsing. Thanks @tredston.
  • #3893 Improved axis default positions so that x axes default to bottom and y axes default to left.
  • #3897 Chart data can now be entirely replaced using chart.data = {...}.
  • #3960 Improved element transitioning by removing color exceptions.
  • #4034 Tooltips with no content are not anymore drawn. Thanks @samueljo
  • #4043, #4153 Added a showcase page for samples.
  • #4078 Added a better error message when the chart type is incorrect.
  • #3914 Time scale internals improved to be simpler and more efficient. Thanks @tredston
  • #4166 Enhanced the responsive documentation.
  • #4167 Made it clear that labels need to be specified when using a category axis on a line chart.
  • #4170 Added documentation for updating data.
  • #4178 Reorganize extension docs. Thanks @benmccann
  • #4183 Removed unnecessary variable. Thanks @benmccann

Issues Fixed

  • #2481 chart instanceof Chart now returns true.
  • #3118 Fixed documentation for scatter chart.
  • #3237 Fixed getElementAtEvent() return type documentation.
  • #3490 Added documentation for axes autoSkipPadding option.
  • #3585 Fixed stacked bar charts with log axes.
  • #3792 Fixed stacked bar displaying NaN when all datasets are hidden. Thanks @Jareechang
  • #3842 Removed trailing ':' in tooltip label when dataset label is undefined.
  • #3856 Tooltip callbacks were called on mouse move even if data did not change. Thanks @Jareechang
  • #3883 Fixed deprecated Chart.PluginBase definition.
  • #3860 Correctly handle decimal canvas display size.
  • #3899 Grouped bars that are not stacked are now displayed correctly. Thanks @potatopeelings
  • #3909 Avoid fails from server-side renderings. Thanks @khorolets
  • #3911 Fixed missing onComplete animation argument and updated associated doc.
  • #3945 Fixed use of native reserved keyword as a parameter name.
  • #3960 Fixed element initial implicit transition.
  • #4032 Radar chart are now centered horizontally. Thanks @shirosaki
  • #4039 Fixed line-customTooltips.html example scroll offset. Thanks @el-ee
  • #4062 Fixed misplaced data points on category scale. Thanks @martinzuern
  • #4064 Fixed scale min and max when dataset contains no values. Thanks @GabrielMancik
  • #4086 Fixed pointRadius and pointHitRadius config for radar charts.
  • #4100 Updated the documentation bar chart example to begin at zero.
  • #4105 Ensured that scale width cannot be greater than maxWidth. Thanks @tredston
  • #4140 Fixed shorthand legend: false and title: false.
  • #4149, #4155 Fixed and merged contributing documentation. Thanks @benmccann
  • #4165 Fixed failing instanceof when reading context from iframe or a protected environment.
  • #4192 Fixed legend and title layout options update.
  • #4254 Fixed images being used as a pointStyle not rendering at custom dimensions

Development

  • #3839 Added unit tests for deprecations.
  • #3986 Cleaned up and upgraded unit tests environment.
  • #3988 Introduced unit test based on image comparison.
  • #4075 Refactored gulp coverage task in gulp unittest --coverage.
  • #4076 Moved legend and title in the plugins folder.
  • #4222 Removed executable bit from js files. Thanks @benmccann

More details in the release PR: #4236

Version 2.5.0

08 Feb 20:26
Compare
Choose a tag to compare

Version 2.5 brings some exciting new features to Chart.js. Now, configuration options can be updated at runtime (with some exceptions) just by changing the chart.config.options object and calling chart.update().

More powerful plugins that can be added to an individual chart (instead of globally), but also disabled on a per chart basis. This gives you fine grained control over when plugins interact with your charts. The plugins were changed to support cancelling actions by returning false from any before* plugin calls.

Two new extensions have been added: beforeEvent and afterEvent, respectively called before and after the chart responds to an input event such as a mousemove or a click. The plugin is passed a wrapped version of the event, that implements IEvent.

Breaking Changes

  • #3570 Removed unused Chart.helpers.cancelAnimFrame method.
  • #3669 onHover callback now has 3 parameters. The 2nd parameter is the event that triggered the hover. This was done for consistency with the onClick callback.

Deprecations

  • #3819 IPlugin.afterScaleUpdate: use IPlugin.afterLayout hook instead.
  • #3819 Extending Chart.PlugingBase is not anymore required and is strongly discouraged, instead create/register plugins using plain JavaScript objects (see this example).

New Features

  • #2060 Chart options can now be updated at runtime.
  • #2643 Stacked bar charts now support groupings into smaller stacks. Thanks @potatopeelings
  • #3335 Plugins can now be specified per chart.

Enhancements

  • #1933 Legends can now be hidden dynamically by a plugin at runtime based on the chart size.
  • #2873, #3491, #3506 Chart elements are clipped when outside the chart area. Thanks @KoyoSE
  • #3208 Slow performance using moment.js. Thanks @tredston
  • #3225 Multiple lines of text are now supported in radar chart labels
  • #3514 Add rectRounded point style. Thanks @cmoel
  • #3818 Removed useless initialization steps to improve performance

Issues Fixed

  • #2478 Large x axis labels created odd gaps in the chart
  • #2780 Bar chart when data is 0. Thanks @KoyoSE
  • #2879, #3354 Rotated labels caused issues on the category axis
  • #3141 Axis width incorrectly used ticks.padding option when measuring
  • #3199 Line Chart border width of 0 was ignored.
  • #3412 Long y axis tick text was cutoff
  • #3381 Infinite loop when in certain cases when generating logarithmic ticks.
  • #3387 Fixed legend text alignment
  • #3408 Monotone cubic interpolation broke when two adjacent points had the same x value
  • #3528 null data caused incorrect tooltips for the time scale. Thanks @Jareechang
  • #3585 Logarithmic stacked bar charts don't draw the first dataset
  • #3589 Wrong category size of bars when x axis has min and max options. Thanks @KoyoSE
  • #3591 Correct radar chart tension settings
  • #3592 Correct radar chart documentation name for point radius setting
  • #3603 Fix crash in dataset interaction mode
  • #3605 Documentation for x-axis interaction mode was incorrect. Thanks @weareoutman
  • #3607 Correct link in animation section of documentation. Thanks @38elements
  • #3618 Tooltip label is incorrect on Bar chart when min is defined. Thanks @KoyoSE
  • #3685 bug when calculating if steps fit into scale as a whole number. Thanks @Tarqwyn
  • #3713 Axis label was cutoff when axis was at top of chart. Thanks @KoyoSE
  • #3717 Removed jQuery code from samples. Thanks @KoyoSE
  • #3739 Incorrect use of animation options in doughnut chart docs. Thanks @NtsDK
  • #3741 Axis labels placed incorrectly when axis is at the top of the chart. Thanks @KoyoSE
  • #3763 Pie charts incorrectly calculated the inner radius when cutout percentage was 0.
  • #3772 Fix incorrect anchor link in docs. Thanks @mdewilde
  • #3788 Fixed docs for using Chart.js with CommonJS and ES6 imports. Thanks @Jareechang
  • #3801 Ignore .gitignore file for Bower

Development

  • #3610 Updated documentation for plugin renames. Thanks @compwright
  • #3635 Upgrade to gulp-uglify v2.0.0 to improve build speed. Thanks @jeffcarey
  • #3718, #3795 Refactoring to move platform specific code into it's own module. The ultimate goal is to allow builds for non browser platforms

More details in the release PR: #3840

Version 2.4.0

12 Nov 17:58
Compare
Choose a tag to compare

This version focuses on improving the interactivity of Chart.js. We have new and improved modes for interacting with the graph. For instance, you can now highlight the nearest item easily. It is also easy to define your own tooltip modes with a few simple functions. See all the new modes in the docs. Data animations when adding and removing data have been improved: points now animate in cleanly by default.

Breaking Changes

  • #3356 The default aspect ratio is now correctly applied, meaning that polar, doughnut and radar charts are now rendered with an aspect ratio of 1 (square). The old behavior can be obtained by globally changing the default aspectRatio for each chart type (e.g. Chart.defaults.doughnut.aspectRatio = 2).

New Features

  • #3201 Expose data points info for custom tooltip. Thanks @bydooweedoo
  • #3400 New tooltip and hover interaction modes.
  • #3411 New displayColors option to turn off tooltip color boxes.
  • #3453 New tooltip average and nearest positioning modes.
  • #3460 New line chart fill modes.
  • #3472 Add new caretX and caretY properties to tooltip point.
  • #3474 Charts can now be created from the canvas id.
  • #3476 Layout service now supports configurable padding.
  • #3477 New method to reset() the chart to its initial state.
  • #3494 New tooltips.filter option to filter tooltip items.

Enhancements

  • #3281 Better number formatting for the radial linear scale.
  • #3326 Make charts vertically responsive.
  • #3364 Inject iframe for responsive charts only.
  • #3399 Better animation when adding or removing data.
  • #3400 Improve tooltip and hover Interactions.
  • #3411 Display tooltip color boxes for all tooltips.
  • #3417 Expose the drawBackground tooltip method. Thanks @mjeanroy
  • #3468 Bar chart performance improvements.
  • #3504 Reorganize, cleanup and enhance samples.
  • Update installation instructions in README.

Issues Fixed

  • #3133 Skip non finite data points when determining scale sizes. Thanks @bcongdon
  • #3323 Fix the legend drawing when labels.usePointStyle is true.
  • #3324 Compute correct tooltip size when there is no title present.
  • #3325 Specifically handle multiline strings for doughnut charts.
  • #3341 Fix scale documentation.
  • #3356 Fix initial aspect ratio when not responsive.
  • #3356 Fix radar default aspect ratio and samples.
  • #3357 Fix documentation typos. Thanks @kant
  • #3358 Fix title overflow by using maxWidth fillText() argument. Thanks @dylan-kerr
  • #3361 Fix HTML legend string for polar area charts to match doughnut charts.
  • #3409 Generate ticks using only min, max and stepSize when all specified. Thanks @fewstera
  • #3421 Fix bubble chart tooltip callback to use correct labels.
  • #3443 Properly merge colors for the tooltip labels.
  • #3444 Fix documentation comparison table "check" character. Thanks @tiesont
  • #3446 Fix tooltip caret position.
  • #3450 Fix options.events option merging.
  • #3474 Prevent exception when an invalid canvas/context/id is provided.
  • #3490 Add missing tick autoSkipPadding option documentation. Thanks @bretjb
  • #3516 Fix a documentation typo. Thanks @varatep
  • #3522 Fix code and documentation typos. Thanks @jsoref
  • #3527 Fix iframe resize handler when re-attached to DOM.
  • Move reverse option for labels to correct section in docs.

Development

  • #3281 Refactor ticks generators and formatters.
  • #3356 Gulp command switch to run specific test files.
  • #3414 Fix NPM watchify dependency. Thanks @fewstera
  • #3473 Extend ESLint to unit test.
  • #3526 Bump ESLint to v3.x.

More details in the release PR: #3551

Version 2.3.0

22 Sep 19:03
Compare
Choose a tag to compare

This version adds back native bower support. We were able to get a name that matches in case with npm. bower install chart.js. Huge props to @simonbrunel for getting our build system working and fully automated.

New Features

  • Support a minimum unit on the time scale. Set time.minUnit to one of the time scale units to use. #3254 Thanks @ianks

Issues Fixed

  • An issue where a zero width border was incorrectly drawn. #3241 Thanks @Pikamander2
  • Fixed an incorrect link in the docs #3280 Thanks @trantorLiu
  • Return the correct tooltip labels when 2 category axes are used. #3278 Thanks @etimberg
  • Improve performance of the time scale by caching intermediate results. #3211 Thanks @desowin
  • Fixed an error when the legend of a pie chart was toggled and there were multiple datasets of different lengths. #3309 Thanks @zachpanz88

Development

More details in the release PR: #3321