Skip to content

Commit 2c73460

Browse files
authored
fix(PieChart): fix hideDataLabel on measure not hiding data labels (#499)
1 parent f5932fa commit 2c73460

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

packages/charts/src/components/PieChart/PieChart.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,9 +120,10 @@ const PieChart: FC<PieChartProps> = forwardRef((props: PieChartProps, ref: Ref<a
120120
);
121121

122122
const label = useMemo(() => {
123+
if(measure.hideDataLabel) return null;
123124
return {
124125
position: 'outside',
125-
content: measure.hideDataLabel ?? measure.DataLabel,
126+
content: measure.DataLabel,
126127
formatter: measure.formatter
127128
};
128129
}, [measure]);

0 commit comments

Comments
 (0)