Features · axis

Tick label overlap avoidance

native

Auto-skip, stagger or hide overlapping labels

Matrix status native. Verification runtime · strong. ChartKit option: ChartKitChartSpecV1.axes.x.autoSkip.

autoSkip true drops crowded category labels instead of tilting them. false draws every label. Numeric ticks skip on collision unless it is false. Drawn on createRenderer([line]).

Source: packages/core/src/generated/schema.ts:1044

ChartKit spec

Passed validate() during npm run matrix:refresh. The SVG is the server render.

Units rose in Q2.Units rose in Q2.40455055Q1Q2
{
  "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
  },
  "axes": {
    "x": {
      "autoSkip": false
    }
  }
}

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: axis.ticks.autoskip.md.

LibraryStatusOptionVerificationSource
Chart.jsnativegrep: autoSkipgrep · weakchart.js/dist/types/index.d.ts:3127
RechartsnativeXAxis.interval, XAxis.minTickGaptypes · strongrecharts/types/cartesian/XAxis.d.ts:125
Apache EChartsnativexAxis.axisLabel.hideOverlaptypes · strongecharts/types/dist/shared.d.ts:2814
HighchartsnativexAxis.labels.staggerLines, xAxis.labels.autoRotationtypes · stronghighcharts/highcharts.d.ts:108041
Plotly.jspartiallayout.xaxis.automargintypes · strongplot-schema.json#layout.layoutAttributes.xaxis.automargin
Nivonone—absence · absence—
VictorynativeVictoryAxis.fixLabelOverlaptypes · strongvictory-axis/lib/victory-axis.d.ts:7
visxnone—absence · absence—
ApexChartsnativexaxis.labels.hideOverlappingLabelstypes · strongapexcharts/types/apexcharts.d.ts:4911
Tremor (npm)unknown—unverified · unknown—
Observable Plotnativegrep: tickSpacinggrep · weak@observablehq/plot/src/scales.d.ts:572
Vega-Litenativegrep: labelOverlapgrep · weak1474: "labelOverlap"
AG Chartsnativegrep: avoidCollisionsgrep · weakag-charts-types/dist/types/src/presets/gauge/linearGaugeOptions.d.ts:70
amCharts 5nativegrep: minGridDistancegrep · weak@amcharts/amcharts5/examples/xy-stacked-step/config.json:83
Google Chartsnativegrep: showTextEverygrep · weak@types/google.visualization/index.d.ts:539
uPlotpartialOptions.axes.spacetypes · stronguplot/dist/uPlot.d.ts:1096
TradingView Lightweight Chartspartialgrep: tickMarkMaxCharacterLengthgrep · weak1464: tickMarkMaxCharacterLength?
MUI X Chartsnativegrep: tickLabelIntervalgrep · weak@mui/x-charts/ChartsYAxis/useAxisTicksProps.d.ts:24
Mermaid (chart-ish diagrams only)none—absence · absence—
AntV G2unknowngrep: labelAutoHideunverified · unknown—