graph » widgets
widgets
[ root » graph » widgets ]
A way to extend default ZingChart functionality with object syntax. Refer to the Widgets Tutorial for more information.
Original JSON: ... widgets: [{ type: "myWidget", x: 100, y: 200, ... }] ... JavaScript Code: ... zingchart.widgets.myWidget = { parse : function(data) { return { graphs: [{...}], labels: [{...}], shapes: [{...}] }; } };
Attribute | Type | Description |
---|---|---|
OBJECT_KEY_NAME | Any | Custom configuration data for widget. |
type | String | Type of the widget. The zingchart.widgets.myWidget object must exist and define a parse method returning an object with graphs, labels, and shapes collections which will be injected in the original JSON. |