SideTitleWidget is missing
Describe the bug The method SideTitleWidget is missing or isn't defined.
To Reproduce In the bargraph example. Try to use the getTitles function
` Widget getTitles(double value, TitleMeta meta) { const style = TextStyle( color: Colors.white, fontWeight: FontWeight.bold, fontSize: 14, ); Widget text; switch (value.toInt()) { case 0: text = const Text('M', style: style); break; case 1: text = const Text('T', style: style); break; case 2: text = const Text('W', style: style); break; case 3: text = const Text('T', style: style); break; case 4: text = const Text('F', style: style); break; case 5: text = const Text('S', style: style); break; case 6: text = const Text('S', style: style); break; default: text = const Text('', style: style); break; } return SideTitleWidget( axisSide: meta.axisSide, space: 16, child: text, );
}`
Screenshots https://www.dropbox.com/s/23cet9n4eet0gmm/Screen%20Shot%202022-05-29%20at%2011.37.40%20AM.png?dl=0
Versions
- Flutter version: 2.10.3
- FLChart version: 0.50.6
You need to run the master example in the master branch code.
It seems you are using a stable version. You need to check our stable branch to use examples in your code.
I have the same problem and i was following this https://github.com/imaNNeoFighT/fl_chart/blob/master/example/lib/line_chart/samples/line_chart_sample2.dart example
Version flutter: 2.16.2 FLChart: 0.50.6
You need to replace master with stable in your URL:
https://github.com/imaNNeoFighT/fl_chart/blob/stable/example/lib/line_chart/samples/line_chart_sample2.dart