From 600d18ac31919cc63ada01d167deb7126eacdc46 Mon Sep 17 00:00:00 2001 From: jianneng-fit2cloud Date: Wed, 4 Sep 2024 18:52:57 +0800 Subject: [PATCH] =?UTF-8?q?style(=E5=9B=BE=E8=A1=A8-=E5=9C=B0=E5=9B=BE):?= =?UTF-8?q?=20=E8=B0=83=E6=95=B4=E6=B8=90=E5=8F=98=E8=89=B2=E6=B8=85?= =?UTF-8?q?=E6=96=B0=E3=80=81=E7=81=AB=E7=BA=A2=E3=80=81=E7=81=B5=E5=8A=A8?= =?UTF-8?q?=E9=A2=9C=E8=89=B2=E6=B8=90=E5=8F=98=E6=96=B9=E5=90=91=E4=B8=BA?= =?UTF-8?q?=E6=B5=85=E8=87=B3=E6=B7=B1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- core/core-frontend/src/views/chart/components/js/util.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/core/core-frontend/src/views/chart/components/js/util.ts b/core/core-frontend/src/views/chart/components/js/util.ts index bd58bd3048..8573bb2ae4 100644 --- a/core/core-frontend/src/views/chart/components/js/util.ts +++ b/core/core-frontend/src/views/chart/components/js/util.ts @@ -705,7 +705,10 @@ export const stepsColor = (start, end, steps, gamma) => { export const getMapColorCases = colorCases => { const cloneColorCases = JSON.parse(JSON.stringify(colorCases)) return cloneColorCases.map(colorItem => { - const curColors = colorItem.colors + let curColors = colorItem.colors + if (['fresh', 'red', 'spiritual'].includes(colorItem.value)) { + curColors = colorItem.colors.reverse() + } const len = curColors.length const start = curColors[0] const end = curColors[len - 1]