Skip to content

Commit

Permalink
Add declaration for Decimation plugin (#9172)
Browse files Browse the repository at this point in the history
  • Loading branch information
kurkle committed May 28, 2021
1 parent 188da82 commit aa6a973
Show file tree
Hide file tree
Showing 2 changed files with 54 additions and 0 deletions.
2 changes: 2 additions & 0 deletions types/index.esm.d.ts
Expand Up @@ -1953,6 +1953,8 @@ export class BasePlatform {
export class BasicPlatform extends BasePlatform {}
export class DomPlatform extends BasePlatform {}

export const Decimation: Plugin;

export const enum DecimationAlgorithm {
lttb = 'lttb',
minmax = 'min-max',
Expand Down
52 changes: 52 additions & 0 deletions types/tests/register.ts
@@ -0,0 +1,52 @@
import {
Chart,
ArcElement,
LineElement,
BarElement,
PointElement,
BarController,
BubbleController,
DoughnutController,
LineController,
PieController,
PolarAreaController,
RadarController,
ScatterController,
CategoryScale,
LinearScale,
LogarithmicScale,
RadialLinearScale,
TimeScale,
TimeSeriesScale,
Decimation,
Filler,
Legend,
Title,
Tooltip
} from '../index.esm';

Chart.register(
ArcElement,
LineElement,
BarElement,
PointElement,
BarController,
BubbleController,
DoughnutController,
LineController,
PieController,
PolarAreaController,
RadarController,
ScatterController,
CategoryScale,
LinearScale,
LogarithmicScale,
RadialLinearScale,
TimeScale,
TimeSeriesScale,
Decimation,
Filler,
Legend,
Title,
Tooltip
);

0 comments on commit aa6a973

Please sign in to comment.