From: Jukka Kurkela Date: Fri, 5 Feb 2021 22:39:45 +0000 (+0200) Subject: Update types for indexAxis (#8389) X-Git-Tag: v3.0.0-beta.11~43 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6e56ae64f76bcdc98f69555bad8c6ebe3795bdb8;p=thirdparty%2FChart.js.git Update types for indexAxis (#8389) * Add indexAxis to CoreChartOptions * Update types for indexAxis --- diff --git a/types/index.esm.d.ts b/types/index.esm.d.ts index 5b414f99a..581db43d3 100644 --- a/types/index.esm.d.ts +++ b/types/index.esm.d.ts @@ -63,6 +63,11 @@ export interface ParsingOptions { } export interface ControllerDatasetOptions extends ParsingOptions { + /** + * The base axis of the chart. 'x' for vertical charts and 'y' for horizontal charts. + * @default 'x' + */ + indexAxis: 'x' | 'y'; /** * How to clip relative to chartArea. Positive value allows overflow, negative value clips that many pixels inside chartArea. 0 = clip at chartArea. Clipping can also be configured per side: clip: {left: 5, top: false, right: -2, bottom: 0} */ @@ -86,11 +91,6 @@ export interface BarControllerDatasetOptions extends ControllerDatasetOptions, ScriptableAndArrayOptions, ScriptableAndArrayOptions { - /** - * The base axis of the dataset. 'x' for vertical bars and 'y' for horizontal bars. - * @default 'x' - */ - indexAxis: 'x' | 'y'; /** * The ID of the x axis to plot this dataset on. */ @@ -1341,6 +1341,12 @@ export interface CoreChartOptions extends ParsingOptions { animation: Scriptable; }; + /** + * The base axis of the chart. 'x' for vertical charts and 'y' for horizontal charts. + * @default 'x' + */ + indexAxis: 'x' | 'y'; + /** * base color * @see Defaults.color