- {{ bar.name }}: {{ dataLabel({v: bar.proportion * 100, s: '%', r: FINAL_CONFIG.style.chart.legend.roundingPercentage}) }} ({{ applyDataLabel(
+ {{ applyDataLabel(
FINAL_CONFIG.style.chart.dataLabel.formatter,
bar.value,
- dataLabel({
+ `${bar.name}: ${dataLabel({v: bar.proportion * 100, s: '%', r: FINAL_CONFIG.style.chart.legend.roundingPercentage})} (${dataLabel({
p: FINAL_CONFIG.style.chart.legend.prefix,
v: bar.value,
s: FINAL_CONFIG.style.chart.legend.suffix,
r: FINAL_CONFIG.style.chart.legend.roundingValue
- }),
- { datapoint: bar, seriesIndex: i }
+ })})`,
+ { datapoint: bar, seriesIndex: i, type: 'barDatapoint' }
)
- }})
+ }}
@@ -797,17 +797,17 @@ defineExpose({
:fill="FINAL_CONFIG.style.chart.legend.color"
:font-size="FINAL_CONFIG.style.chart.legend.fontSize / 1.5"
>
- {{ displayArcPercentage(arc, bar.fill.donut) }} ({{ applyDataLabel(
+ {{ applyDataLabel(
FINAL_CONFIG.style.chart.dataLabel.formatter,
arc.value,
- dataLabel({
+ `${displayArcPercentage(arc, bar.fill.donut)} (${dataLabel({
p: FINAL_CONFIG.style.chart.legend.prefix,
v: arc.value,
s: FINAL_CONFIG.style.chart.legend.suffix,
r: FINAL_CONFIG.style.chart.legend.roundingValue
- }),
- { datapoint: arc, seriesIndex: i }
- )}})
+ })})`,
+ { datapoint: arc, seriesIndex: i, type: 'donutDatapoint' }
+ )}}
- {{ bar.name }}: {{ dataLabel({v: bar.proportion * 100, s: '%', r: FINAL_CONFIG.style.chart.legend.roundingPercentage}) }} ({{ applyDataLabel(
+ {{ applyDataLabel(
FINAL_CONFIG.style.chart.dataLabel.formatter,
bar.value,
- dataLabel({
+ `${bar.name}: ${dataLabel({v: bar.proportion * 100, s: '%', r: FINAL_CONFIG.style.chart.legend.roundingPercentage})} (${dataLabel({
p: FINAL_CONFIG.style.chart.legend.prefix,
v: bar.value,
s: FINAL_CONFIG.style.chart.legend.suffix,
r: FINAL_CONFIG.style.chart.legend.roundingValue
- }),
- { datapoint: bar, seriesIndex: i }
- )}})
+ })})`,
+ { datapoint: bar, seriesIndex: i, type: 'barDatapoint' }
+ )}}
@@ -938,17 +938,17 @@ defineExpose({
:fill="FINAL_CONFIG.style.chart.legend.color"
:font-size="FINAL_CONFIG.style.chart.legend.fontSize / 1.5"
>
- {{ displayArcPercentage(arc, bar.fill.donut) }} ({{ applyDataLabel(
+ {{ applyDataLabel(
FINAL_CONFIG.style.chart.dataLabel.formatter,
arc.value,
- dataLabel({
+ `${displayArcPercentage(arc, bar.fill.donut)} (${dataLabel({
p: FINAL_CONFIG.style.chart.legend.prefix,
v: arc.value,
s: FINAL_CONFIG.style.chart.legend.suffix,
r: FINAL_CONFIG.style.chart.legend.roundingValue
- }),
- { datapoint: arc, seriesIndex: i }
- )}})
+ })})`,
+ { datapoint: arc, seriesIndex: i, type: 'donutDatapoint' }
+ )}}