# Interface: LegendItem

# Properties

# borderRadius

• Optional borderRadius: number | BorderRadius

Border radius of the legend box

Since

3.1.0

# Defined in

types/index.d.ts:2291


# datasetIndex

• Optional datasetIndex: number

Index of the associated dataset

# Defined in

types/index.d.ts:2296


# fillStyle

• Optional fillStyle: Color

Fill style of the legend box

# Defined in

types/index.d.ts:2306


# fontColor

• Optional fontColor: Color

Font color for the text Defaults to LegendOptions.labels.color

# Defined in

types/index.d.ts:2312


# hidden

• Optional hidden: boolean

If true, this item represents a hidden dataset. Label will be rendered with a strike-through effect

# Defined in

types/index.d.ts:2317


# index

• Optional index: number

Index the associated label in the labels array

# Defined in

types/index.d.ts:2301


# lineCap

• Optional lineCap: CanvasLineCap

For box border.

See

https://developer.mozilla.org/en/docs/Web/API/CanvasRenderingContext2D/lineCap

# Defined in

types/index.d.ts:2323


# lineDash

• Optional lineDash: number[]

For box border.

See

https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/setLineDash

# Defined in

types/index.d.ts:2329


# lineDashOffset

• Optional lineDashOffset: number

For box border.

See

https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/lineDashOffset

# Defined in

types/index.d.ts:2335


# lineJoin

• Optional lineJoin: CanvasLineJoin

For box border.

See

https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/lineJoin

# Defined in

types/index.d.ts:2341


# lineWidth

• Optional lineWidth: number

Width of box border

# Defined in

types/index.d.ts:2346


# pointStyle

• Optional pointStyle: PointStyle

Point style of the legend box (only used if usePointStyle is true)

# Defined in

types/index.d.ts:2356


# rotation

• Optional rotation: number

Rotation of the point in degrees (only used if usePointStyle is true)

# Defined in

types/index.d.ts:2361


# strokeStyle

• Optional strokeStyle: Color

Stroke style of the legend box

# Defined in

types/index.d.ts:2351


# text

• text: string

Label that will be displayed

# Defined in

types/index.d.ts:2285


# textAlign

• Optional textAlign: TextAlign

Text alignment

# Defined in

types/index.d.ts:2366