New to Kendo UI for AngularStart a free 30-day trial

Represents the Kendo UI for Angular Chart Legend configuration (see example).

Definition

Package:@progress/kendo-angular-charts

Selector:kendo-chart-legend

Syntax:

html
<kendo-chart>
 <kendo-chart-legend position="top" [visible]="true">
 </kendo-chart-legend>
</kendo-chart>

Inputs

align

"center" | "start" | "end"

Specifies the alignment of the legend. The legend is horizontally aligned when legend.position is set to "top" or "bottom". The legend is vertically aligned when legend.position is set to "left" or "right".

Default:

'center'

Specifies the background color of the legend. Accepts a valid CSS color string, including hex and rgb.

Default:

'white'

Specifies the border configuration of the legend.

Specifies the focus highlight configuration of the legend.

height

number

Specifies the height of the legend.

Specifies the inactive items configuration of the legend.

Specifies the item configuration of the legend.

Specifies the labels configuration of the legend.

margin

number | Margin

Specifies the margin of the Chart legend. A numeric value sets all paddings.

Default:

5

Specifies the markers configuration of the legend.

offsetX

number

Specifies the X offset of the Chart legend. The offset is relative to the default position of the legend. For example, a value of 20 moves the legend 20 pixels to the right of its initial position. Negative values move the legend to the left of its current position.

Default:

0

offsetY

number

Specifies the Y offset of the chart legend. The offset is relative to the current position of the legend. For example, a value of 20 moves the legend 20 pixels down from its initial position. Negative values move the legend upwards from its current position.

Default:

0

orientation

"vertical" | "horizontal"

Specifies the orientation of the legend items.

Default:

'vertical'

Specifies the padding of the Chart legend. A numeric value sets all paddings.

Default:

5

position

"top" | "bottom" | "left" | "right" | "custom"

Specifies the positions of the Chart legend. Setting the legend position to custom allows you to position the legend using the legend.offsetX and legend.offsetY options.

Default:

'right'

reverse

boolean

Determines whether the legend items are reversed.

Default:

false

spacing

number

Specifies the spacing between legend items.

Specifies the title configuration of the legend.

visible

boolean

Determines whether the Chart displays the legend. By default, the Chart legend is visible.

Default:

true

width

number

Specifies the width of the legend.

Methods

Updates the component fields with the specified values and refreshes the Chart.

Use this method when the configuration values cannot be set through the template.

Parameters:changesany

An object containing the updated input fields.