Be notified of new releases
Create your free GitHub account today to subscribe to this repository for new releases and build software alongside 28 million developers.Sign up
Now, if CSS mode is enabled, the color option is always ignored. Before, in some cases (like combining a color function with CSS mode) some unexpected behaviour could occur.
This new rule is conistent with the original aim that in CSS mode no local color definitions apply.
In CSS mode (
So for example a website stylesheet for a corporate design may now simply also style the pie charts and their content plug-ins as well, re-using a common color scheme (maybe defined with a language like Less or Sass), or enabling style switching or easy changes to a common color scheme at one place without having to edit and script files accordingly.
The optional rotation animation (see 'rotation' option) has been changed from a SMIL to a CSS implementation. This does not yet improve browser support, since Internet Explorer and MS Edge still don't support the rotation, but while the older SMIL implementation will probably never work in MS Edge, the CSS transformation is, as far as I know, a feature that will be supported at least by Edge in the (hopefully near) future.
Also this new implementation allows for the rotation option to be used inside an inner option object, too. This means, if you have multiple rings in one chart, not only the outer one, but any ring may be rotated (independently of the others).
You may now use a form input element as value source, and an event handler is automatically added to that input which updates the chart upon changes.
Also, titles may now be added to the chart and/or single values (like rings), comparable to the title attribute of HTML elements. Desktop browsers, for example, will show these titles when the mouse cursor rests on the chart.
Optional boolean argument "replace" added to setupProgressPie() function in order to support optional replacement of previous setups instead of always just merging new options into previous setup.
- New options for alignment of ring graph with background circle and for adding a margin or padding around the graph.
- The content plug-in API has been improved. It now supports drawing content either in the foreground or in the background.
- Also, more than one content plug-in can now be added to a graph.
- New content plug-in image for adding external images as e.g. background or ring content.
- SVG rendering rewritten, produces simpler, more compact SVG code.
- New features include optional animated transitions, adding CSS classes to the diagrams in order to enable external styling, and extending the “double pie/ring” feature to “multiple rings”, removing the limitation to max. 2 values per chart.
- The API for content plug-ins has been extended, allowing for a content plug-in to suppress the actual chart output (e.g. if it would be completely occluded by the content plug-in anyway).
Some changes might slightly affect backwards compatibility, especially the separator string (by default a space) is now only inserted if there's actually something to separate: If the selected target element is completely empty, only the SVG will be inserted without the separator string behind it. The previous versions always inserted the separator.
See README for more.