(fix)(chat-sdk)Fix the pie chart display conditions

This commit is contained in:
WDEP
2025-05-14 13:56:28 +08:00
parent 08705c9d3b
commit 522ad09ebf

View File

@@ -122,7 +122,7 @@ const ChatMsg: React.FC<Props> = ({
}
const isMetricPie =
metricFields.length > 0 &&
categoryField.length > 0 &&
metricFields?.length === 1 &&
(isMobile ? dataSource?.length <= 5 : dataSource?.length <= 10) &&
dataSource.every(item => item[metricFields[0].bizName] > 0);