Constructor - create a new chart instance.
Actions during the constructor:
Parent DOM node the SVG element will be attached to.
Configuration object.
Static
Private
#chartMapper for chart types and chart controllers.
Static
colorAll embedded color palettes. Set another with setActiveColorPalette.
Static
Private
#cssSome CSS rules for synamic styles are added to the HEAD of the document.
Static
Private
#activeCurrent color palette. Set another one with setActiveColorPalette.
Width of parent element.
Height of parent element.
Width of chart without paddings.
Height of chart without paddings.s
The generated root SVG element.
Config object that is created in the constrructor or setConfig() methiod.
Private
#controllerController that is in charge of drawing the chart.
Hash where key = serie and value = whether it is selected or nor not.
Private
#dataChart data object. Set during the chart() method.
Private
#defsElement that contains definitions, for example for gradients.
Private
#drawElement where the config.drawOnDarta method will paint in. Only created when config.drawOnData is specified.
Element where series will be attached to.
SVG group element that wraps the focused value element.
Private
#onScoped callback to call when a legend item gets clicked.
Private
#onScoped callback to call when a legend items receives a keyboard ENTER press.
Private
#onPrivate
#onPrivate
#onPrivate
#listenersStatic
setSet the configuration for this chart instance. The idea is that this method does things that need to be done only once for a chart and that chart does things for drawing the charts and can happen multiple times, for example if you need to display a new set of data.
Actions during this method:
Configuration object.
Writing the chart data.
Data object.
Private
#addPrivate
#addPrivate
#addGet the color or gradient for this serie for a specific property.
Serie object.
Serie index.
Color or gradient.
Get the point color or gradient for this serie.
Serie object.
Serie index.
Color or gradient.
Get the stroke color or gradient for this serie.
Serie object.
Serie index.
Color or gradient.
Get the fill color or gradient for this serie.
Serie object.
Serie index.
Color or gradient.
Adds an event listener to a node and adds it to the #listenersToRemoveAfterConfigChange array as well, so we can remove them in one place.
Node to add the listener to.
Name of event.
Function that needs to be executed.
Capture or not.
Private
#onPrivate
#onPrivate
#onPrivate
#onPrivate
#onPrivate
#onGenerated using TypeDoc
SvgChart class.