From 144cad8200d13089fddcddcea904c816d03dbf02 Mon Sep 17 00:00:00 2001 From: Matthew Date: Tue, 23 Jul 2019 05:27:06 +1000 Subject: [PATCH] AxisOptions.autoRotation add missing boolean type (#36919) Reference: https://api.highcharts.com/highcharts/xAxis.labels.autoRotation --- types/highcharts/index.d.ts | 3 ++- types/highcharts/test/index.ts | 6 ++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/types/highcharts/index.d.ts b/types/highcharts/index.d.ts index b30515ef66..9836936919 100644 --- a/types/highcharts/index.d.ts +++ b/types/highcharts/index.d.ts @@ -8,6 +8,7 @@ // ArunkeshavaReddy Sankaramaddi // Dolan Miu // Jack Siman +// Matthew Wills // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped // TypeScript Version: 2.3 @@ -82,7 +83,7 @@ declare namespace Highcharts { * @default [-45] * @since 4.1.0 */ - autoRotation?: number[]; + autoRotation?: number[] | boolean; /** * When each category width is more than this many pixels, we don't apply auto rotation. Instead, we lay out the * axis label with word wrap. A lower limit makes sense when the label contains multiple short words that don't diff --git a/types/highcharts/test/index.ts b/types/highcharts/test/index.ts index 358064b877..be8747af30 100644 --- a/types/highcharts/test/index.ts +++ b/types/highcharts/test/index.ts @@ -2397,6 +2397,12 @@ function test_AxisOptions() { ['minute', [1, 2, 5, 10, 15, 30]]], visible: true }; + + const labelsOptionUnions: Highcharts.AxisOptions = { + labels: { + autoRotation: false + } + }; } function test_AxisObject() {