Keyboard Interaction in React Chart
The Chart component followed the keyboard interaction guideline, making it easy for people who use assistive technologies (AT) and those who completely rely on keyboard navigation. The following keyboard shortcuts are supported by the Chart component.
Here’s the updated table with an additional column that converts the Windows key combinations to their Mac equivalents:
| Windows | macOS | Action |
|---|---|---|
| Alt + J | Option + J | Moves the focus to the chart element. |
| Tab | Tab | Moves the focus to the next element in the chart. |
| Shift + Tab | Shift + Tab | Moves the focus to the previous element in the chart. |
| Down Arrow | Down Arrow | Moves the focus to the data point left side from the selected point. |
| Up Arrow | Up Arrow | Moves the focus to the data point right side from the selected point. |
| Left Arrow | Left Arrow | Moves the focus to the next series in the chart. |
| Right Arrow | Right Arrow | Moves the focus to the previous series in the chart. |
| ESC | ESC | Cancel the tooltip for the data point. |
| Down/Left Arrow | Down/Left Arrow | Moves the focus to the legend left side from the selected legend. |
| Up/Right Arrow | Up/Right Arrow | Moves the focus to the legend right side from the selected legend. |
| Enter/Space | Return/Space | Toggles the visibility of the corresponding series. |
| Ctrl + + | Command + + | Zoom in the chart. |
| Ctrl + - | Command + - | Zoom out the chart. |
| Down/Up Arrow | Down/Up Arrow | Pan the chart vertically. |
| Left/Right Arrow | Left/Right Arrow | Pan the chart horizontally. |
| R | R | Reset the zoomed chart. |