From: Kashif Shamaz Date: Sun, 21 Feb 2021 16:17:01 +0000 (+0530) Subject: Added 'hidden: boolean' to ControllerDatasetOptions type and documented the field... X-Git-Tag: v3.0.0-beta.12~35 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=832bf9144a5573fd084877935727c1e13e22c2b3;p=thirdparty%2FChart.js.git Added 'hidden: boolean' to ControllerDatasetOptions type and documented the field's usage in Dataset configuration section (#8478) --- diff --git a/docs/docs/general/data-structures.md b/docs/docs/general/data-structures.md index 17913bcbf..8bc65bf18 100644 --- a/docs/docs/general/data-structures.md +++ b/docs/docs/general/data-structures.md @@ -71,6 +71,7 @@ In this mode, property name is used for `index` scale and value for `value` scal | `order` | `number` | The drawing order of dataset. Also affects order for stacking, tooltip and legend. | `stack` | `string` | The ID of the group to which this dataset belongs to (when stacked, each group will be a separate stack). | `parsing` | `boolean`\|`object` | How to parse the dataset. The parsing can be disabled by specifying parsing: false at chart options or dataset. If parsing is disabled, data must be sorted and in the formats the associated chart type and scales use internally. +| `hidden` | `boolean` | Configure the visibility of the dataset. Using `hidden: true` will hide the dataset from being rendered in the Chart. ### parsing diff --git a/types/index.esm.d.ts b/types/index.esm.d.ts index 5a4802179..64449af8f 100644 --- a/types/index.esm.d.ts +++ b/types/index.esm.d.ts @@ -87,6 +87,11 @@ export interface ControllerDatasetOptions extends ParsingOptions { * The ID of the group to which this dataset belongs to (when stacked, each group will be a separate stack). */ stack: string; + /** + * Configures the visibility state of the dataset. Set it to true, to hide the dataset from the chart. + * @default false + */ + hidden: boolean; } export interface BarControllerDatasetOptions