From d1f7bc130a3c4383f71b0542d7cbf7ef0d18ebe2 Mon Sep 17 00:00:00 2001 From: "lily.zhang" Date: Fri, 29 Oct 2021 12:05:06 +0800 Subject: [PATCH] cxw-010203 --- src/utils/gol/bubbleWord.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/utils/gol/bubbleWord.js b/src/utils/gol/bubbleWord.js index e2f2d5b..6bb4314 100644 --- a/src/utils/gol/bubbleWord.js +++ b/src/utils/gol/bubbleWord.js @@ -1,7 +1,7 @@ /* * @Author: your name * @Date: 2021-10-21 11:36:36 - * @LastEditTime: 2021-10-21 11:43:38 + * @LastEditTime: 2021-10-29 12:01:52 * @LastEditors: Please set LastEditors * @Description: In User Settings Edit * @FilePath: /data-show/src/utils/gol/bubbleWord.js @@ -21,6 +21,7 @@ function bubbleChart(data = [], format = []) { data.forEach((item) => { temp.push(item[format[1]]); }); + console.log(data) maxValue = Math.max.apply(null, temp); // 气泡颜色数组 let color = [ @@ -39,12 +40,12 @@ function bubbleChart(data = [], format = []) { // 气泡数据 let bubbleData = []; // 气泡基础大小 - let basicSize = 70; + let basicSize = 30; // 节点之间的斥力因子,值越大,气泡间距越大 let repulsion = 380; // 根据气泡数量配置基础大小和斥力因子(以实际情况进行适当调整,使气泡合理分布) if (data.length >= 5 && data.length < 10) { - basicSize = 50; + basicSize = 30; repulsion = 230; } if (data.length >= 10 && data.length < 20) {