From fca8506505ea64f31c750c52b0525fe717464041 Mon Sep 17 00:00:00 2001 From: Matt Gibbs Date: Fri, 25 Sep 2015 17:48:02 -0400 Subject: [PATCH] Adding in the four methods for Chartist.Base --- chartist/chartist.d.ts | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/chartist/chartist.d.ts b/chartist/chartist.d.ts index 290354ebb..7c2971e57 100644 --- a/chartist/chartist.d.ts +++ b/chartist/chartist.d.ts @@ -8,6 +8,8 @@ declare module Chartist { Pie: IChartistPieChart; Bar: IChartistBarChart; Line: IChartistLineChart; + + Svg: any; } interface IResponsiveOptionTuple extends Array { @@ -21,10 +23,27 @@ declare module Chartist { defaultOptions: T; options: T; responsiveOptions: Array>; + + // this most likely doesn't need to be exposed to the user eventEmitter: any; + supportsForeignObject: boolean; supportsAnimations: boolean; resizeListener: any; + + update(data: any, options?: T, override?: boolean): void; + detatch(): void; + on(event: string, handler: Function): IChartistBase; + + /** + * Use this function to un-register event handlers. If the handler function parameter is omitted all handlers for the given event will be un-registered. + * + * @method off + * @param event {string} Name of the event for which a handler should be removed + * @param handler {Function} The handler function that that was previously used to register a new event handler. This handler will be removed from the event handler list. If this parameter is omitted then all event handlers for the given event are removed from the list. + * @returns {IChartistBase} + */ + off(event: string, handler?: Function): IChartistBase; } interface IChartistPieChart extends IChartistBase {