UNPKG

@nova-ui/charts

Version:

Nova Charts is a library created to provide potential consumers with solutions for various data visualizations that conform with the Nova Design Language. It's designed to solve common patterns identified by UX designers, but also be very flexible so that

47 lines (46 loc) 1.99 kB
import { Selection } from "d3-selection"; import { ChartPlugin } from "./common/chart-plugin"; import { DataManager } from "./common/data-manager"; import { EventBus } from "./common/event-bus"; import { Lasagna } from "./common/lasagna"; import { RenderEngine } from "./common/render-engine"; import { D3Selection, IAccessors, IChart, IChartConfiguration, IChartEvent, IChartPlugin, IChartSeries, IRenderStateData } from "./common/types"; import { IGrid } from "./grid/types"; export declare class Chart implements IChart { private grid; configuration?: IChartConfiguration | undefined; readonly eventBus: EventBus<IChartEvent<any>>; element: HTMLElement; target?: D3Selection<SVGSVGElement>; filterDefs?: Selection<SVGDefsElement, any, SVGElement, any>; private dataManager; private renderEngine; private updateSubject; private updateDimensionsSubject; private seriesStatesSubject; private plugins; constructor(grid: IGrid, configuration?: IChartConfiguration | undefined); getEventBus(): EventBus<IChartEvent>; getDataManager(): DataManager; getRenderEngine(): RenderEngine; getGrid(): IGrid; addPlugin(plugin: IChartPlugin): void; removePlugin(classRef: typeof ChartPlugin): void; addPlugins(...plugins: IChartPlugin[]): void; removePlugins(...classRefs: (typeof ChartPlugin)[]): void; hasPlugin(classRef: typeof ChartPlugin): boolean; build(element: HTMLElement): void; private configureCssFilters; protected buildDataManager(): DataManager; protected buildGrid(): void; protected buildRenderEngine(lasagna: Lasagna, dataManager: DataManager): RenderEngine; update(seriesSet: IChartSeries<IAccessors>[]): void; updateDimensions(): void; initialize(): void; destroy(): void; setSeriesStates(renderStateData: IRenderStateData[]): void; private onUpdate; private onUpdateDimensions; private updateTargetDimensions; private onSetSeriesStates; }