Picks the colour of one bar from its row: its index, its x and its value y, whichever way the bars point.
index
x
y
typedef ChartBarColor = Color? Function(int index, double x, double y);