Skip to content

Documentation / @ripl/charts / ColorLegendOptions

Interface: ColorLegendOptions

Defined in: charts/src/components/color-legend.ts:32

Visual options for a ColorLegend.

Properties

PropertyTypeDescriptionDefined in
font?stringCSS font shorthand for the value labels.charts/src/components/color-legend.ts:44
fontColor?stringColour of the value labels.charts/src/components/color-legend.ts:46
format?(value) => stringFormats a domain value into a label (defaults to formatNumber at 2 dp).charts/src/components/color-legend.ts:42
labelGap?numberGap between the bar and its labels in pixels.charts/src/components/color-legend.ts:48
orientation?ColorLegendOrientationWhether the colour bar runs horizontally or vertically. Defaults to horizontal.charts/src/components/color-legend.ts:34
segments?numberNumber of solid segments used to approximate the gradient.charts/src/components/color-legend.ts:38
thickness?numberThickness of the colour bar in pixels (height when horizontal, width when vertical).charts/src/components/color-legend.ts:36
tickCount?numberNumber of value labels to render.charts/src/components/color-legend.ts:40