mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-10-03 14:27:04 +00:00
Merge pull request #12836 from nmykhailova/types-2.0
Added LegendObject and legend property to ChartObject
This commit is contained in:
@@ -2212,6 +2212,7 @@ function test_ChartObject() {
|
||||
chart.showLoading("Loading label");
|
||||
var firstXAxis = chart.xAxis[0];
|
||||
var firstYAxis = chart.yAxis[0];
|
||||
var legend = chart.legend;
|
||||
}
|
||||
|
||||
function test_ElementObject() {
|
||||
@@ -2338,3 +2339,8 @@ function test_SeriesObject() {
|
||||
var xAxis = series.xAxis;
|
||||
var yAxis = series.yAxis;
|
||||
}
|
||||
function test_LegendObject() {
|
||||
var legend = $('#container').highcharts().legend;
|
||||
legend.update({});
|
||||
legend.update({}, false);
|
||||
}
|
||||
|
||||
Vendored
+12
@@ -5977,6 +5977,8 @@ declare namespace Highcharts {
|
||||
yAxis: AxisObject[];
|
||||
|
||||
renderer: RendererObject;
|
||||
|
||||
legend: LegendObject;
|
||||
}
|
||||
|
||||
interface Chart {
|
||||
@@ -6456,6 +6458,16 @@ declare namespace Highcharts {
|
||||
*/
|
||||
yAxis: AxisObject;
|
||||
}
|
||||
|
||||
interface LegendObject {
|
||||
/**
|
||||
* Update the legend with new options.
|
||||
* @param {LegendOptions} options New options that will be merged into the legend's existing options.
|
||||
* @param [boolean] redraw - Whether to redraw the chart. Defaults to true.
|
||||
* @since 5.0.0
|
||||
*/
|
||||
update(options: LegendOptions, redraw?: boolean): void;
|
||||
}
|
||||
}
|
||||
|
||||
declare global {
|
||||
|
||||
Reference in New Issue
Block a user