diff --git a/src/types/index.d.ts b/src/types/index.d.ts index da4ab6a13..9dbf5b1de 100644 --- a/src/types/index.d.ts +++ b/src/types/index.d.ts @@ -12,6 +12,7 @@ import {ChartArea, Padding, Point} from './geometric.js'; import {LayoutItem, LayoutPosition} from './layout.js'; import {RenderTextOpts} from './helpers/helpers.canvas.js'; import {CanvasFontSpec} from '../helpers/helpers.options.js'; +import type {ColorsPluginOptions} from '../plugins/plugin.colors.js'; export {EasingFunction} from '../helpers/helpers.easing.js'; export {default as ArcElement, ArcProps} from '../elements/element.arc.js'; @@ -2791,6 +2792,7 @@ export interface TooltipItem { } export interface PluginOptionsByType { + colors: ColorsPluginOptions; decimation: DecimationOptions; filler: FillerOptions; legend: LegendOptions; diff --git a/test/types/plugins/plugin.colors/colors.ts b/test/types/plugins/plugin.colors/colors.ts new file mode 100644 index 000000000..180709bdb --- /dev/null +++ b/test/types/plugins/plugin.colors/colors.ts @@ -0,0 +1,19 @@ +import { Chart } from '../../../../src/types.js'; + +const chart = new Chart('id', { + type: 'bubble', + data: { + labels: [], + datasets: [{ + data: [] + }] + }, + options: { + plugins: { + colors: { + enabled: true, + forceOverride: false, + } + } + } +});