Web [Charts]: Improve Visx `<Axis/>` API in order to simplify props passing to the tick components
Created by: vovakulikov
This issiue is a follow up for https://github.com/sourcegraph/sourcegraph/pull/39805.
Background
Curretly for chart ticks aria-labels we have to use tickLabelProps
prop of VisxAxis component. But in the same time we use tickComponent
props for custom tick rendering (also because of a11y reasons). It would be better to use only one solution for tick props generation. Unfortanatly tickComponent
doesn't have all needed data that we have inside tickLabelProps
callback.
In this issue we should contribute to @visx/axis
package and extend axis component API (TickRendererProps
props interface) with all needed data for tick aria-labels attributes (tick raw value, list of all ticks in axis).