Enumerated values
Many config members take one of a fixed set of string values (renderer: 'bar', curve.type: 'monotoneX'), and each member's reference page lists its own. This page lists them by the TypeScript type they form. Every type here is exported from @mochart/core, so code that builds configs can name one in its own signature (function setRenderer(renderer: RendererType)) instead of indexing into a config type as SeriesConfig['renderer']. The few exported value constants (AUTO, TYPE_NUMBER, …) are on the API page.
This page is generated from the library source (the values from the constants each type is built from, the uses from the config type declarations), so it lists exactly what the shipped .d.ts accepts. Anchors are stable: link to any type as #TypeName.
ChartType
The chart family: cartesian ('xy') or pie.
- Values:
'xy','pie' - Used by:
chart.type
DataType
The data type of the category axis values.
- Values:
'string','number','date' - Used by:
categoryAxis.type
Scale
How the category axis spaces its categories.
- Values:
'ordinal','linear','log' - Used by:
categoryAxis.scale
ValueAxisScale
How the value axis places values: by difference (linear) or by ratio (log).
- Values:
'linear','log' - Used by:
valueAxes.scale
AxisSide
Which side of the plot an axis is drawn on: the start (left or bottom) or the end.
- Values:
'start','end' - Used by:
categoryAxis.side,valueAxes.side
Anchor
Where a tick label is anchored relative to its tick.
- Values:
'start','end','middle' - Used by:
categoryAxis.tickLabel.anchor,categoryAxis.minorTickLabel.anchor,categoryAxis.thresholds.title.anchor,valueAxes.tickLabel.anchor,valueAxes.thresholds.title.anchor,valueAxes.minorTickLabel.anchor
ThresholdTitleSide
Which side of a threshold its title sits on, or inside a threshold range.
- Values:
'low','high','inside' - Used by:
categoryAxis.thresholds.title.side,valueAxes.thresholds.title.side
Position
Whether the title or legend sits above or below the plot.
- Values:
'top','bottom' - Used by:
legend.position,title.position
Align
Horizontal alignment.
- Values:
'left','center','right' - Used by:
legend.align,title.align
TooltipValueAlign
Which edge of the tooltip its values are aligned to: left puts the label and value in one run of text, right floats the values to the far edge.
- Values:
'left','right' - Used by:
tooltip.valueAlign
VerticalAlign
Vertical alignment.
- Values:
'top','middle','bottom' - Used by:
title.verticalAlign
RendererType
How a series draws its values.
- Values:
'bar','line','area','none' - Used by:
series.renderer
CurveType
The interpolation curve for line and area series.
- Values:
'linear','monotoneX','monotoneY','basis','cardinal','catmullRom','natural','step','stepBefore','stepAfter' - Used by:
series.curve.type
MissingValueMode
How a line or area series treats categories with no value.
- Values:
'break','connect','base' - Used by:
series.missingValueMode
CapType
The shape of the outer end of a bar.
- Values:
'point','curve','round' - Used by:
series.cap.type,seriesStacks.outerCap.type
LabelPosition
Where a series value label sits relative to its shape.
- Values:
'inside','center','outside' - Used by:
series.label.position,series.label.aboveBase.position,series.label.belowBase.position
MarkerShape
The symbol drawn at each series value.
- Values:
'circle','cross','diamond','square','star','triangle','wye' - Used by:
series.marker.shape
MarkerSizeScale
How marker area scales with the marker size property.
- Values:
'sqrt','linear' - Used by:
series.marker.sizeScale
StepPeriod
The calendar period a date axis steps its ticks or thresholds by: the first category of each period on an ordinal scale, the period boundaries on a linear one.
- Values:
'second','minute','hour','day','week','month','year' - Used by:
categoryAxis.tickStep.interval,categoryAxis.tickStep.minorInterval,categoryAxis.thresholdStep.interval
CategoryValueIntervalPeriod
The fixed-width period a linear date axis accepts as its categoryValueInterval, the axis value distance one category slot covers.
- Values:
'second','minute','hour','day','week' - Used by:
categoryAxis.categoryValueInterval
ColorMode
The keywords a series style color accepts in place of a CSS color, resolved against the palette.
- Values:
'series','same','seriesIndex','categoryIndex' - Used by:
series.errorBar.style.normal.strokeColor,series.errorBar.style.focused.strokeColor,series.errorBar.style.defocused.strokeColor,series.label.textStyle.normal.fillColor,series.label.textStyle.normal.strokeColor,series.label.textStyle.focused.fillColor,series.label.textStyle.focused.strokeColor,series.label.textStyle.defocused.fillColor,series.label.textStyle.defocused.strokeColor,series.shapeStyle.normal.fillColor,series.shapeStyle.normal.strokeColor,series.shapeStyle.focused.fillColor,series.shapeStyle.focused.strokeColor,series.shapeStyle.defocused.fillColor,series.shapeStyle.defocused.strokeColor,series.marker.style.normal.fillColor,series.marker.style.normal.strokeColor,series.marker.style.focused.fillColor,series.marker.style.focused.strokeColor,series.marker.style.defocused.fillColor,series.marker.style.defocused.strokeColor
ColorInterpolation
The color space a series color scale interpolates in.
- Values:
'rgb','hsl','lab','hcl' - Used by:
series.colorScale.interpolation
PatternType
The fill pattern a patterns entry draws.
- Values:
'lines','crosshatch','dots' - Used by:
patterns.type
PieLabelType
What a pie slice label shows.
- Values:
'value','percent','title','valuePercent','percentValue','titleValue','titlePercent' - Used by:
pie.label.type
PieTooltipValueType
What a pie tooltip row shows: the slice value, its percent or both, without the series title the row already carries.
- Values:
'value','percent','valuePercent','percentValue' - Used by:
pie.tooltip.valueType
DomainChange
How an axis domain change animates relative to the value change.
- Values:
'auto','combined','staged' - Used by:
animation.valueDomainChange,animation.categoryDomainChange
FontWeight
The css font-weight a font member accepts: a hundred from 100 to 900, or one of the css keywords.
- Values:
100,200,300,400,500,600,700,800,900,'normal','bold','lighter','bolder' - Used by:
chart.font.weight,clipIndicator.font.weight,categoryAxis.tickLabel.font.weight,categoryAxis.minorTickLabel.font.weight,categoryAxis.title.font.weight,legend.item.font.weight,pie.centerLabel.font.weight,pie.centerTotal.font.weight,valueAxes.tickLabel.font.weight,valueAxes.minorTickLabel.font.weight,valueAxes.title.font.weight,series.label.font.weight,title.prefix.font.weight,title.suffix.font.weight,title.font.weight,tooltip.font.weight
FontStyle
The css font-style a font member accepts.
- Values:
'normal','italic','oblique' - Used by:
chart.font.style,clipIndicator.font.style,categoryAxis.tickLabel.font.style,categoryAxis.minorTickLabel.font.style,categoryAxis.title.font.style,legend.item.font.style,pie.centerLabel.font.style,pie.centerTotal.font.style,valueAxes.tickLabel.font.style,valueAxes.minorTickLabel.font.style,valueAxes.title.font.style,series.label.font.style,title.prefix.font.style,title.suffix.font.style,title.font.style,tooltip.font.style
AnimationEasing
How an animation's progress is paced over its duration.
- Values:
'linear','sineIn','sineOut','sineInOut','quadIn','quadOut','quadInOut','cubicIn','cubicOut','cubicInOut','quintIn','quintOut','quintInOut','bounceIn','bounceOut','bounceInOut' - Used by:
animation.easing,animation.focusEasing
Auto
The 'auto' keyword, accepted by members that otherwise take a number, a format string, or another enumeration.
- Values:
'auto' - Used by:
clipIndicator.size,categoryAxis.categoryValueInterval,categoryAxis.tickLabel.anchor,categoryAxis.tickLabel.size,categoryAxis.tickLabel.format,categoryAxis.minorTickLabel.anchor,categoryAxis.minorTickLabel.size,categoryAxis.minorTickLabel.format,categoryAxis.valueFormat,categoryAxis.max,categoryAxis.min,categoryAxis.thresholds.title.anchor,categoryAxis.tickCount,categoryAxis.title.size,legend.icon.size,pie.label.valueFormat,pie.label.percentFormat,pie.tooltip.percentFormat,pie.centerTotal.format,valueAxes.tickLabel.anchor,valueAxes.tickLabel.size,valueAxes.tickLabel.format,valueAxes.max,valueAxes.min,valueAxes.thresholds.title.anchor,valueAxes.tickCount,valueAxes.minorTickLabel.anchor,valueAxes.minorTickLabel.size,valueAxes.minorTickLabel.format,valueAxes.title.size,series.valueFormat,series.label.format,series.label.aboveBase.position,series.label.aboveBase.offset,series.label.aboveBase.minPositionFraction,series.label.aboveBase.maxPositionFraction,series.label.belowBase.position,series.label.belowBase.offset,series.label.belowBase.minPositionFraction,series.label.belowBase.maxPositionFraction,tooltip.icon.size
Major
The 'major' keyword, accepted by every minor tick setting to use the value of the matching non-minor setting.
- Values:
'major' - Used by:
categoryAxis.minorTickLabel.truncation.enabled,categoryAxis.minorTickLabel.truncation.tooltipEnabled,categoryAxis.minorTickLabel.truncation.minLength,categoryAxis.minorTickLabel.truncation.maxFraction,categoryAxis.minorTickLabel.visible,categoryAxis.minorTickLabel.front,categoryAxis.minorTickLabel.anchor,categoryAxis.minorTickLabel.size,categoryAxis.minorTickLabel.marginInner,categoryAxis.minorTickLabel.marginOuter,categoryAxis.minorTickLabel.paddingInner,categoryAxis.minorTickLabel.paddingOuter,categoryAxis.minorTickLabel.format,categoryAxis.minorTickLabel.rotation,categoryAxis.minorTickLabel.textStyle.normal.fillColor,categoryAxis.minorTickLabel.textStyle.normal.fillOpacity,categoryAxis.minorTickLabel.textStyle.normal.strokeColor,categoryAxis.minorTickLabel.textStyle.normal.strokeOpacity,categoryAxis.minorTickLabel.textStyle.normal.strokeWidth,categoryAxis.minorTickLabel.textStyle.normal.strokeDashArray,categoryAxis.minorTickLabel.textStyle.focused.fillColor,categoryAxis.minorTickLabel.textStyle.focused.fillOpacity,categoryAxis.minorTickLabel.textStyle.focused.strokeColor,categoryAxis.minorTickLabel.textStyle.focused.strokeOpacity,categoryAxis.minorTickLabel.textStyle.focused.strokeWidth,categoryAxis.minorTickLabel.textStyle.focused.strokeDashArray,categoryAxis.minorTickLabel.textStyle.defocused.fillColor,categoryAxis.minorTickLabel.textStyle.defocused.fillOpacity,categoryAxis.minorTickLabel.textStyle.defocused.strokeColor,categoryAxis.minorTickLabel.textStyle.defocused.strokeOpacity,categoryAxis.minorTickLabel.textStyle.defocused.strokeWidth,categoryAxis.minorTickLabel.textStyle.defocused.strokeDashArray,categoryAxis.minorTickLabel.font.family,categoryAxis.minorTickLabel.font.size,categoryAxis.minorTickLabel.font.weight,categoryAxis.minorTickLabel.font.style,categoryAxis.minorGridLine.visible,categoryAxis.minorGridLine.front,categoryAxis.minorGridLine.style.normal.strokeColor,categoryAxis.minorGridLine.style.normal.strokeOpacity,categoryAxis.minorGridLine.style.normal.strokeWidth,categoryAxis.minorGridLine.style.normal.strokeDashArray,categoryAxis.minorGridLine.style.focused.strokeColor,categoryAxis.minorGridLine.style.focused.strokeOpacity,categoryAxis.minorGridLine.style.focused.strokeWidth,categoryAxis.minorGridLine.style.focused.strokeDashArray,categoryAxis.minorGridLine.style.defocused.strokeColor,categoryAxis.minorGridLine.style.defocused.strokeOpacity,categoryAxis.minorGridLine.style.defocused.strokeWidth,categoryAxis.minorGridLine.style.defocused.strokeDashArray,categoryAxis.minorTickMark.visible,categoryAxis.minorTickMark.front,categoryAxis.minorTickMark.size,categoryAxis.minorTickMark.marginInner,categoryAxis.minorTickMark.style.normal.strokeColor,categoryAxis.minorTickMark.style.normal.strokeOpacity,categoryAxis.minorTickMark.style.normal.strokeWidth,categoryAxis.minorTickMark.style.normal.strokeDashArray,categoryAxis.minorTickMark.style.focused.strokeColor,categoryAxis.minorTickMark.style.focused.strokeOpacity,categoryAxis.minorTickMark.style.focused.strokeWidth,categoryAxis.minorTickMark.style.focused.strokeDashArray,categoryAxis.minorTickMark.style.defocused.strokeColor,categoryAxis.minorTickMark.style.defocused.strokeOpacity,categoryAxis.minorTickMark.style.defocused.strokeWidth,categoryAxis.minorTickMark.style.defocused.strokeDashArray,valueAxes.minorGridLine.visible,valueAxes.minorGridLine.front,valueAxes.minorGridLine.style.normal.strokeColor,valueAxes.minorGridLine.style.normal.strokeOpacity,valueAxes.minorGridLine.style.normal.strokeWidth,valueAxes.minorGridLine.style.normal.strokeDashArray,valueAxes.minorGridLine.style.focused.strokeColor,valueAxes.minorGridLine.style.focused.strokeOpacity,valueAxes.minorGridLine.style.focused.strokeWidth,valueAxes.minorGridLine.style.focused.strokeDashArray,valueAxes.minorGridLine.style.defocused.strokeColor,valueAxes.minorGridLine.style.defocused.strokeOpacity,valueAxes.minorGridLine.style.defocused.strokeWidth,valueAxes.minorGridLine.style.defocused.strokeDashArray,valueAxes.minorTickLabel.visible,valueAxes.minorTickLabel.front,valueAxes.minorTickLabel.anchor,valueAxes.minorTickLabel.size,valueAxes.minorTickLabel.marginInner,valueAxes.minorTickLabel.marginOuter,valueAxes.minorTickLabel.paddingInner,valueAxes.minorTickLabel.paddingOuter,valueAxes.minorTickLabel.format,valueAxes.minorTickLabel.rotation,valueAxes.minorTickLabel.textStyle.normal.fillColor,valueAxes.minorTickLabel.textStyle.normal.fillOpacity,valueAxes.minorTickLabel.textStyle.normal.strokeColor,valueAxes.minorTickLabel.textStyle.normal.strokeOpacity,valueAxes.minorTickLabel.textStyle.normal.strokeWidth,valueAxes.minorTickLabel.textStyle.normal.strokeDashArray,valueAxes.minorTickLabel.textStyle.focused.fillColor,valueAxes.minorTickLabel.textStyle.focused.fillOpacity,valueAxes.minorTickLabel.textStyle.focused.strokeColor,valueAxes.minorTickLabel.textStyle.focused.strokeOpacity,valueAxes.minorTickLabel.textStyle.focused.strokeWidth,valueAxes.minorTickLabel.textStyle.focused.strokeDashArray,valueAxes.minorTickLabel.textStyle.defocused.fillColor,valueAxes.minorTickLabel.textStyle.defocused.fillOpacity,valueAxes.minorTickLabel.textStyle.defocused.strokeColor,valueAxes.minorTickLabel.textStyle.defocused.strokeOpacity,valueAxes.minorTickLabel.textStyle.defocused.strokeWidth,valueAxes.minorTickLabel.textStyle.defocused.strokeDashArray,valueAxes.minorTickLabel.font.family,valueAxes.minorTickLabel.font.size,valueAxes.minorTickLabel.font.weight,valueAxes.minorTickLabel.font.style,valueAxes.minorTickMark.visible,valueAxes.minorTickMark.front,valueAxes.minorTickMark.size,valueAxes.minorTickMark.marginInner,valueAxes.minorTickMark.style.normal.strokeColor,valueAxes.minorTickMark.style.normal.strokeOpacity,valueAxes.minorTickMark.style.normal.strokeWidth,valueAxes.minorTickMark.style.normal.strokeDashArray,valueAxes.minorTickMark.style.focused.strokeColor,valueAxes.minorTickMark.style.focused.strokeOpacity,valueAxes.minorTickMark.style.focused.strokeWidth,valueAxes.minorTickMark.style.focused.strokeDashArray,valueAxes.minorTickMark.style.defocused.strokeColor,valueAxes.minorTickMark.style.defocused.strokeOpacity,valueAxes.minorTickMark.style.defocused.strokeWidth,valueAxes.minorTickMark.style.defocused.strokeDashArray