Hi nitish,
You can achieve
your requirement by using the name property in the chart series. By
using the name property, you can customize the
legend text. We have provided a code snippet for your reference.
Please inform us if you require any additional assistance.
Code snippet:
|
series: <ChartSeries>[
StackedColumnSeries<ChartSampleData, String>(
name: chartData.isNotEmpty ? 'Series' : '',
color: Colors.red,
dataSource: chartData,
xValueMapper: (ChartSampleData data, _) => data.x,
yValueMapper: (ChartSampleData data, _) => data.y1,
),
|
Regards,
Lokesh.