Hi Yudhisthir,
Greetings from Syncfusion. We have analyzed your query. When the data label is enabled for the circular chart widget, then the data label will be visible inside the circular chart slices and by default, y-value will be displayed.
The data labels can be positioned outside the slices using the labelPosition property of the series and the data labels are positioned with the connector lines if positioned outside. More information on the connector line can be found using the below user guide.
To use the custom values in the data label, use the dataLabelMapper property of the series to map the values from your data source. Find the code snippet below to achieve the above requirements.
|
SfCircularChart(
series: <CircularSeries<SalesData, String>>[
PieSeries<SalesData, String>(
dataLabelSettings: DataLabelSettings(
isVisible: true,
labelPosition: ChartDataLabelPosition.outside,
),
// Map the values for data labels from data source
dataLabelMapper: (SalesData sales, _) => sales.year,
// Other configurations
)
])
|
The sample for reference can be found below.
Thanks,
Dharani.