Conformance
Chart gives the frame; whether a chart is accessible depends on the plot you draw in it. With the steps below, a chart meets WCAG 2.2 level AA.
Keyboard
Chart adds no keyboard behaviour. A legend that turns series on and off needs buttons with aria-pressed and a visible focus outline. Values shown only on hover need another path: the summary or table next to the chart.
What Chart gives you
- A legend that names every series in text.
- Series colours from Beehexa roles, which keep their contrast in light and dark.
- A tooltip in Beehexa overlay colours, with the values in text.
What your team does
- Give the plot a name:
role="img"and anaria-labelthat says what it shows and the time range. - Put the numbers next to the chart: a sentence with totals, or a table.
- Never use colour as the only cue. Name series, and use a second cue such as a dashed line for a threshold.
- Check that each series mark is at least 3:1 against the surface it sits on.
- Keep the tooltip inside the chart, and don’t put anything in it people can’t get another way.
WCAG criteria
| Criterion | Level | How |
|---|---|---|
| 1.1.1 Non-text Content | A | The plot has a name; the numbers are in text next to it |
| 1.4.1 Use of Color | A | Series are named in the legend; values are in text |
| 1.4.11 Non-text Contrast | AA | Series marks at least 3:1 against their surface |
| 1.4.13 Content on Hover or Focus | AA | The tooltip repeats values that are also on the page |