Skip to content

chartjs-chart-geo v4.3.4 / IColorScaleOptions

Interface: IColorScaleOptions

Extends

  • ILegendScaleOptions

Properties

display

display: boolean

whether to render a color legend

Default

ts
true

Inherited from

ILegendScaleOptions.display

Defined in

work/chartjs-chart-geo/chartjs-chart-geo/src/scales/LegendScale.ts:15


interpolate

interpolate: (normalizedValue) => string | "blues" | "brBG" | "buGn" | "buPu" | "cividis" | "cool" | "cubehelixDefault" | "gnBu" | "greens" | "greys" | "inferno" | "magma" | "orRd" | "oranges" | "pRGn" | "piYG" | "plasma" | "puBu" | "puBuGn" | "puOr" | "puRd" | "purples" | "rainbow" | "rdBu" | "rdGy" | "rdPu" | "rdYlBu" | "rdYlGn" | "reds" | "sinebow" | "spectral" | "turbo" | "viridis" | "warm" | "ylGn" | "ylGnBu" | "ylOrBr" | "ylOrRd"

color interpolation method which is either a function converting a normalized value to string or a well defined string of all the interpolation scales from https://github.com/d3/d3-scale-chromatic. e.g. interpolateBlues -> blues

Default

ts
blues

Defined in

work/chartjs-chart-geo/chartjs-chart-geo/src/scales/ColorScale.ts:120


legend

legend: object

align

align: "left" | "top" | "bottom" | "right"

alignment of the scale, e.g., right means that it is a vertical scale with the ticks on the right side

Default
ts
right

indicatorWidth

indicatorWidth: number

how many pixels should be used for the color bar

Default
ts
10

length

length: number

length of the legend, i.e., for a horizontal scale the width if a value < 1 is given, is it assume to be a ratio of the corresponding chart area

Default
ts
100

margin

margin: number | ChartArea

margin pixels such that it doesn't stick to the edge of the chart

Default
ts
8

position

position: "left" | "top" | "bottom" | "right" | object | "top-left" | "top-right" | "bottom-right" | "bottom-left"

location of the legend on the chart area

Default
ts
bottom-right

width

width: number

how wide the scale is, i.e., for a horizontal scale the height if a value < 1 is given, is it assume to be a ratio of the corresponding chart area

Default
ts
50

Inherited from

ILegendScaleOptions.legend

Defined in

work/chartjs-chart-geo/chartjs-chart-geo/src/scales/LegendScale.ts:23


missing

missing: string

color value to render for missing values

Default

ts
transparent

Defined in

work/chartjs-chart-geo/chartjs-chart-geo/src/scales/ColorScale.ts:165


property

property: string

the property name that stores the value in the data elements

Default

ts
value

Inherited from

ILegendScaleOptions.property

Defined in

work/chartjs-chart-geo/chartjs-chart-geo/src/scales/LegendScale.ts:21


quantize

quantize: number

allows to split the color scale in N quantized equal bins.

Default

ts
0

Defined in

work/chartjs-chart-geo/chartjs-chart-geo/src/scales/ColorScale.ts:171