Annotation styling (dash, colour, opacity)
native
Line dash, colour and opacity of annotations
Matrix status native. Verification types · strong. ChartKit option: ChartKitChartSpecV1.annotations.
dash, color, opacity
Source: chartkit:packages/core/src/generated/schema.ts:69
ChartKit spec
Passed validate() during npm run matrix:refresh. The SVG is the server render.
{
"version": "1",
"type": "line",
"data": [
{
"quarter": "Q1",
"units": 40
},
{
"quarter": "Q2",
"units": 55
}
],
"encoding": {
"x": "quarter",
"y": "units"
},
"a11y": {
"alt": "Units rose in Q2."
},
"size": {
"width": 640,
"height": 260
},
"annotations": [
{
"type": "rule",
"axis": "y",
"value": 50,
"label": "Mark"
}
]
}Other libraries
Option names are the paths recorded in the matrix. A grep-only cell names the identifier that matched, not a render test. Markdown copy: annotation.style.md.
| Library | Status | Option | Verification | Source |
|---|---|---|---|---|
| Chart.js | plugin | — | npm · weak | — |
| Recharts | native | ReferenceLine.strokeDasharray | types · strong | @types/react/index.d.ts:3923 |
| Apache ECharts | native | grep: lineStyle | grep · weak | echarts/types/dist/shared.d.ts:2758 |
| Highcharts | native | grep: dashStyle | grep · weak | highcharts/highcharts.src.d.ts:367 |
| Plotly.js | native | grep: dash | grep · weak | @types/plotly.js/index.d.ts:811 |
| Nivo | native | grep: lineStyle | grep · weak | @nivo/core/index.d.ts:333 |
| Victory | manual | VictoryBarProps.dataComponent | mechanism · weak | victory-core/lib/victory-util/common-props.d.ts:9 |
| visx | manual | Group | mechanism · weak | @visx/group/lib/Group.d.ts:15 |
| ApexCharts | native | grep: strokeDashArray | grep · weak | apexcharts/types/apexcharts.d.ts:2104 |
| Tremor (npm) | none | — | absence · absence | — |
| Observable Plot | native | grep: strokeDasharray | grep · weak | @observablehq/plot/src/mark.d.ts:357 |
| Vega-Lite | native | grep: strokeDash | grep · weak | 736: "strokeDash" |
| AG Charts | native | grep: lineDash | grep · weak | ag-charts-types/dist/types/src/presets/gauge/radialGaugeOptions.d.ts:5 |
| amCharts 5 | native | grep: strokeDasharray | grep · weak | @amcharts/amcharts5/.internal/charts/xy/XYChart.d.ts:37 |
| Google Charts | unknown | — | conflict · unknown | — |
| uPlot | unknown | — | conflict · unknown | — |
| TradingView Lightweight Charts | native | grep: lineStyle | grep · weak | 73:export declare enum LineStyle { |
| MUI X Charts | native | grep: lineStyle | grep · weak | @mui/x-charts/index.d.ts:11 |
| Mermaid (chart-ish diagrams only) | unknown | — | conflict · unknown | — |
| AntV G2 | native | grep: lineDash | grep · weak | @antv/g2/lib/theme/create.d.ts:207 |