From b2a2c329459925e8d032a75045963e462e9333f9 Mon Sep 17 00:00:00 2001 From: jianneng-fit2cloud Date: Wed, 4 Dec 2024 09:36:43 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E5=9B=BE=E8=A1=A8):=20=E4=BF=AE=E5=A4=8D?= =?UTF-8?q?=E5=9C=B0=E5=9B=BE=E5=9B=BE=E4=BE=8B=E9=85=8D=E7=BD=AE=E5=9B=BE?= =?UTF-8?q?=E5=BD=A2=E5=A4=A7=E5=B0=8F=E6=97=A0=E6=95=88=E7=9A=84=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/js/panel/charts/map/map.ts | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/map/map.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/map/map.ts index 472d8283d1..dd9441be2b 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/map/map.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/map/map.ts @@ -389,9 +389,22 @@ export class Map extends L7PlotChartView { }, 'l7plot-legend__category-marker': { ...LEGEND_SHAPE_STYLE_MAP[legend.icon], - width: '9px', - height: '9px', - ...(legend.icon === 'triangle' ? {} : { border: '0.01px solid #f4f4f4' }) + width: legend.size + 'px', + height: legend.size + 'px', + ...(legend.icon === 'triangle' + ? { + ...LEGEND_SHAPE_STYLE_MAP[legend.icon]['triangle'], + borderLeft: `${legend.size / 2}px solid transparent`, + borderRight: `${legend.size / 2}px solid transparent`, + borderBottom: `${legend.size}px solid var(--bgColor)` + } + : { border: '0.01px solid #f4f4f4' }), + ...(legend.icon === 'diamond' + ? { + transform: 'rotate(45deg)', + marginBottom: `${legend.size / 4}px` + } + : {}) } } }