From 105119f987e6e16d3a152649394f6052e5936b8f Mon Sep 17 00:00:00 2001
From: riku <risaku@163.com>
Date: 星期二, 24 十二月 2024 11:17:53 +0800
Subject: [PATCH] 调整动画速率

---
 src/utils/map/grid.js |   20 ++++++++++++++++++++
 1 files changed, 20 insertions(+), 0 deletions(-)

diff --git a/src/utils/map/grid.js b/src/utils/map/grid.js
index e5d5273..bb3807f 100644
--- a/src/utils/map/grid.js
+++ b/src/utils/map/grid.js
@@ -185,6 +185,26 @@
   },
 
   drawGridColor(gridViews, texts, factorName) {
+    // new Promise((resolve, reject) => {
+    //   gridViews.forEach((g, i) => {
+    //     const data = parseFloat(texts[i]);
+    //     const { color, nextColor, range, nextRange } =
+    //       Legend.getStandardColorAndNext(factorName, data);
+    //     const ratio = (data - range) / (nextRange - range);
+    //     const _color = getColorBetweenTwoColors(
+    //       color.map((v) => v * 255),
+    //       nextColor.map((v) => v * 255),
+    //       ratio
+    //     );
+    //     resolve({ g, _color, color });
+    //   });
+    // }).then((res) => {
+    //   const { g, _color, color } = res;
+    //   g.setOptions({
+    //     fillColor: _color,
+    //     fillOpacity: color[3]
+    //   });
+    // });
     gridViews.forEach((g, i) => {
       const data = parseFloat(texts[i]);
       const { color, nextColor, range, nextRange } =

--
Gitblit v1.9.3